(self)
| 131 | self.my_py_filename = fix_ext_py(__file__) |
| 132 | |
| 133 | def test_traced_func_linear(self): |
| 134 | result = self.tracer.runfunc(traced_func_linear, 2, 5) |
| 135 | self.assertEqual(result, 7) |
| 136 | |
| 137 | # all lines are executed once |
| 138 | expected = {} |
| 139 | firstlineno = get_firstlineno(traced_func_linear) |
| 140 | for i in range(1, 5): |
| 141 | expected[(self.my_py_filename, firstlineno + i)] = 1 |
| 142 | |
| 143 | self.assertEqual(self.tracer.results().counts, expected) |
| 144 | |
| 145 | @unittest.skipIf(os.environ.get('PYTHON_UOPS_OPTIMIZE') == '0', |
| 146 | "Line counts differ when JIT optimizer is disabled") |
nothing calls this directly
no test coverage detected