def test_success(self): (returncode, err, out) = agent.cmd({'cmdline': wmic.cmdline(self.wmi_target_alive)+['SELECT * FROM Win32_Service']}) self.assertEqual(0, returncode)
def test_error(self): (returncode, err, out) = agent.cmd({'cmdline': wmic.cmdline(self.wmi_target_dead)}) self.assertEqual(1, returncode)