add tests for base command, integration test, fix few things