(self)
| 68 | wmi_exec_query("SELECT * FROM CIM_DataFile") |
| 69 | |
| 70 | def test_wmi_query_multiple_rows(self): |
| 71 | # Multiple instances should have an extra null separator |
| 72 | r = wmi_exec_query("SELECT ProcessId FROM Win32_Process WHERE ProcessId < 1000") |
| 73 | self.assertNotStartsWith(r, "\0") |
| 74 | self.assertNotEndsWith(r, "\0") |
| 75 | it = iter(r.split("\0")) |
| 76 | try: |
| 77 | while True: |
| 78 | self.assertRegex(next(it), r"ProcessId=\d+") |
| 79 | self.assertEqual("", next(it)) |
| 80 | except StopIteration: |
| 81 | pass |
| 82 | |
| 83 | def test_wmi_query_threads(self): |
| 84 | from concurrent.futures import ThreadPoolExecutor |
nothing calls this directly
no test coverage detected