runcmd: more tests for api client