diff options
| author | TheGeogeo <57634077+TheGeogeo@users.noreply.github.com> | 2026-11-30 17:36:27 +0100 |
|---|---|---|
| committer | TheGeogeo <57634077+TheGeogeo@users.noreply.github.com> | 2026-11-30 17:36:27 +0100 |
| commit | c6a8f7164b892242ea1462960d3b64fdbfe6ce5a (patch) | |
| tree | a3679333b328c0bf1b68f741f725bd89df53de97 /tests/test_run_gpu_tests_python_assembler.py | |
| parent | 5d72958bfa191073bd1fe5fc1c7e8d6bed499091 (diff) | |
| parent | 08e42a516097e5a645c5728a88177c7d08d9093e (diff) | |
Merge origin/main into d3d12-frame-time-stats
main moved the frame meter's five-second lines into a function of their
own that may run on another thread: the frame times are logged where the
meter decides a five-second line is due, on the presenting thread, as
before. The nearest-rank test's comment said 0.95 * 100 is not 95.0 in
f64; it is: ranks are whole numbers so that no float can move one, and
the case pins the rounding direction (review).
Diffstat (limited to 'tests/test_run_gpu_tests_python_assembler.py')
| -rw-r--r-- | tests/test_run_gpu_tests_python_assembler.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/test_run_gpu_tests_python_assembler.py b/tests/test_run_gpu_tests_python_assembler.py index d817f4ec0..fd61b6a9d 100644 --- a/tests/test_run_gpu_tests_python_assembler.py +++ b/tests/test_run_gpu_tests_python_assembler.py | |||
| @@ -20,6 +20,14 @@ import run_gpu_tests | |||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | class PythonAssemblerTests(unittest.TestCase): | 22 | class PythonAssemblerTests(unittest.TestCase): |
| 23 | def test_native_assembler_error_preserves_undecodable_diagnostics(self): | ||
| 24 | run = subprocess.run | ||
| 25 | child = [sys.executable, "-c", "import sys; sys.stderr.buffer.write(b'bad operand \\xff'); sys.exit(1)"] | ||
| 26 | with patch.object(run_gpu_tests.subprocess, "run", side_effect=lambda _, **kw: run(child, **kw)): | ||
| 27 | with self.assertRaises(RuntimeError) as raised: | ||
| 28 | run_gpu_tests.spirv_as("", "unused.spv") | ||
| 29 | self.assertIn(r"bad operand \xff", str(raised.exception)) | ||
| 30 | |||
| 23 | def test_resolve_assembler_auto_and_explicit(self) -> None: | 31 | def test_resolve_assembler_auto_and_explicit(self) -> None: |
| 24 | self.assertEqual(run_gpu_tests.resolve_assembler("python"), "python") | 32 | self.assertEqual(run_gpu_tests.resolve_assembler("python"), "python") |
| 25 | self.assertEqual(run_gpu_tests.resolve_assembler("spirv-as"), "spirv-as") | 33 | self.assertEqual(run_gpu_tests.resolve_assembler("spirv-as"), "spirv-as") |