def test_spawn_with_data(command, data): r = spawn(command, data=data) r.wait() assert r.out == 'at\nat\n' assert r.ok
def test_spawn_no_data(): r = spawn('echo m') r.wait() assert r.out.strip() == 'm' assert r.ok