fix tests/mark as expected failure
authorJacob Lifshay <programmerjake@gmail.com>
Thu, 12 May 2022 03:06:31 +0000 (20:06 -0700)
committerJacob Lifshay <programmerjake@gmail.com>
Thu, 12 May 2022 03:06:31 +0000 (20:06 -0700)
18 files changed:
src/ieee754/cordic/test/test_fp_pipe.py
src/ieee754/cordic/test/test_fpsin_cos.py
src/ieee754/fclass/test/test_fclass_pipe.py
src/ieee754/fcvt/test/test_fcvt_pipe_32_16.py
src/ieee754/fcvt/test/test_fcvt_pipe_64_16.py
src/ieee754/fpdiv/test/test_fpdiv_pipe.py
src/ieee754/fpdiv/test/test_fpdiv_pipe_16.py
src/ieee754/fpdiv/test/test_fpdiv_pipe_32.py
src/ieee754/fpdiv/test/test_fprsqrt_pipe.py
src/ieee754/fpdiv/test/test_fprsqrt_pipe_16.py
src/ieee754/fpdiv/test/test_fprsqrt_pipe_32.py
src/ieee754/fpdiv/test/test_fpsqrt_pipe.py
src/ieee754/fpdiv/test/test_fpsqrt_pipe_16.py
src/ieee754/fpdiv/test/test_fpsqrt_pipe_32.py
src/ieee754/fpdiv/test/test_fpsqrt_pipe_64.py
src/ieee754/part/test/test_partsig.py
src/ieee754/part/test/test_partsig_scope.py
src/ieee754/part_mul_add/test/test_multiply.py

index 921a122342573de34d849fae752c9ed3eb86a343..e7404b7dde2705fe84118034a20e3a1ca6dc3e92 100644 (file)
@@ -79,6 +79,7 @@ class SinCosTestCase(FHDLTestCase):
                 z]):
             sim.run()
 
                 z]):
             sim.run()
 
+    @unittest.expectedFailure  # FIXME: missing attribute `dut.p.data_i`
     def test_rand(self):
         inputs = []
         for i in range(20000):
     def test_rand(self):
         inputs = []
         for i in range(20000):
@@ -89,6 +90,7 @@ class SinCosTestCase(FHDLTestCase):
         outputs = zip(sines, cosines)
         self.run_test(iter(inputs), outputs=iter(outputs))
 
         outputs = zip(sines, cosines)
         self.run_test(iter(inputs), outputs=iter(outputs))
 
+    @unittest.expectedFailure  # FIXME: missing attribute `dut.p.data_i`
     def test_pi_2(self):
         inputs = [Float32(0.5), Float32(1/3), Float32(2/3),
                   Float32(-.5), Float32(0.001)]
     def test_pi_2(self):
         inputs = [Float32(0.5), Float32(1/3), Float32(2/3),
                   Float32(-.5), Float32(0.001)]
index c004cbcd89c560ab1db88b244d1009d4464487c4..5c619e0c31c599de5d93ae92abb73ed3177b5c31 100644 (file)
@@ -89,6 +89,9 @@ class SinCosTestCase(FHDLTestCase):
         x = Float32(1/2)
         self.run_test_assert(x, bits=32)
 
         x = Float32(1/2)
         self.run_test_assert(x, bits=32)
 
+    @unittest.skip("FIXME: test takes too long, create Simulation once and "
+                   "test all cases rather than creating a Simulation for "
+                   "each case")
     def test_rand(self):
         for i in range(10000):
             z = 2*i/10000 - 1
     def test_rand(self):
         for i in range(10000):
             z = 2*i/10000 - 1
index bd52af7c602c74f661352697ef151804b6e52a19..f1e936a9767d436cc846cddd3739bd5614bf6d47 100644 (file)
@@ -64,16 +64,22 @@ def fclass_64(x):
 
 
 class TestFClassPipe(unittest.TestCase):
 
 
 class TestFClassPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_class_pipe_f16(self):
         dut = FPClassMuxInOut(16, 16, 4, op_wid=1)
         runfp(dut, 16, "test_fclass_pipe_f16", Float16, fclass_16,
               True, n_vals=100)
 
     def test_class_pipe_f16(self):
         dut = FPClassMuxInOut(16, 16, 4, op_wid=1)
         runfp(dut, 16, "test_fclass_pipe_f16", Float16, fclass_16,
               True, n_vals=100)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_class_pipe_f32(self):
         dut = FPClassMuxInOut(32, 32, 4, op_wid=1)
         runfp(dut, 32, "test_fclass_pipe_f32", Float32, fclass_32,
               True, n_vals=100)
 
     def test_class_pipe_f32(self):
         dut = FPClassMuxInOut(32, 32, 4, op_wid=1)
         runfp(dut, 32, "test_fclass_pipe_f32", Float32, fclass_32,
               True, n_vals=100)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_class_pipe_f64(self):
         dut = FPClassMuxInOut(64, 64, 4, op_wid=1)
         runfp(dut, 64, "test_fclass_pipe_f64", Float64, fclass_64,
     def test_class_pipe_f64(self):
         dut = FPClassMuxInOut(64, 64, 4, op_wid=1)
         runfp(dut, 64, "test_fclass_pipe_f64", Float64, fclass_64,
@@ -81,16 +87,22 @@ class TestFClassPipe(unittest.TestCase):
 
 
 class TestFClassPipeCoverage(unittest.TestCase):
 
 
 class TestFClassPipeCoverage(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_class_f16(self):
         dut = FPClassMuxInOut(16, 16, 4, op_wid=1)
         run_pipe_fp(dut, 16, "fclass16", unit_test_half, Float16, None,
                     fclass_16, 100, single_op=True)
 
     def test_pipe_class_f16(self):
         dut = FPClassMuxInOut(16, 16, 4, op_wid=1)
         run_pipe_fp(dut, 16, "fclass16", unit_test_half, Float16, None,
                     fclass_16, 100, single_op=True)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_class_f32(self):
         dut = FPClassMuxInOut(32, 32, 4, op_wid=1)
         run_pipe_fp(dut, 32, "fclass32", unit_test_half, Float32, None,
                     fclass_32, 100, single_op=True)
 
     def test_pipe_class_f32(self):
         dut = FPClassMuxInOut(32, 32, 4, op_wid=1)
         run_pipe_fp(dut, 32, "fclass32", unit_test_half, Float32, None,
                     fclass_32, 100, single_op=True)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_class_f64(self):
         dut = FPClassMuxInOut(64, 64, 4, op_wid=1)
         run_pipe_fp(dut, 64, "fclass64", unit_test_half, Float64, None,
     def test_pipe_class_f64(self):
         dut = FPClassMuxInOut(64, 64, 4, op_wid=1)
         run_pipe_fp(dut, 64, "fclass64", unit_test_half, Float64, None,
index 8c803a75daaf6355f9e23ab17d34254d5b88ca2e..558e102db049d94c890d06001af46acc4d36b6af 100644 (file)
@@ -16,6 +16,8 @@ def fcvt_16(x):
 
 
 class TestFClassPipe(unittest.TestCase):
 
 
 class TestFClassPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_fp32_16(self):
         dut = FPCVTDownMuxInOut(32, 16, 4)
         run_pipe_fp(dut, 32, "fcvt", unit_test_single, Float32,
     def test_pipe_fp32_16(self):
         dut = FPCVTDownMuxInOut(32, 16, 4)
         run_pipe_fp(dut, 32, "fcvt", unit_test_single, Float32,
index 89613c04a2e242bfa16cfbd57c0ac6cac812f3d5..1a1dc3a5626fe7d525ff62378ff7c02aea564753 100644 (file)
@@ -16,6 +16,8 @@ def fcvt_16(x):
 
 
 class TestFClassPipe(unittest.TestCase):
 
 
 class TestFClassPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'NextControl' object has no attribute 'ready_i'
+    @unittest.expectedFailure
     def test_pipe_fp64_16(self):
         dut = FPCVTDownMuxInOut(64, 16, 4)
         run_pipe_fp(dut, 64, "fcvt", unit_test_single, Float64,
     def test_pipe_fp64_16(self):
         dut = FPCVTDownMuxInOut(64, 16, 4)
         run_pipe_fp(dut, 64, "fcvt", unit_test_single, Float64,
index 55713500f25f79be6b4eb88566b8e7405629e1e9..d90bbcddc83e18e06584f15c30be3b1dabee9392 100644 (file)
@@ -11,6 +11,8 @@ from operator import truediv as div
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_div_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_div_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
@@ -18,6 +20,8 @@ class TestDivPipe(unittest.TestCase):
         runfp(dut, 16, "test_fpdiv_pipe_fp16", Float16, div,
               opcode=opcode)
 
         runfp(dut, 16, "test_fpdiv_pipe_fp16", Float16, div,
               opcode=opcode)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_div_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_div_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
@@ -25,6 +29,8 @@ class TestDivPipe(unittest.TestCase):
         runfp(dut, 32, "test_fpdiv_pipe_fp32", Float32, div,
               opcode=opcode)
 
         runfp(dut, 32, "test_fpdiv_pipe_fp32", Float32, div,
               opcode=opcode)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_div_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_div_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 136c1bf340ab12ec1ff098ea00cc3fb31f35dc6e..82113af3a1dc42764b3ca87ed3cdfd339d332433 100644 (file)
@@ -13,6 +13,8 @@ from operator import truediv as div
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
index d84fa3052b38a05ed2bdd275e01258df0ec57560..df964fd22d151e7b0d4cd21e37ae83f75586c624 100644 (file)
@@ -13,6 +13,8 @@ from operator import truediv as div
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'NextControl' object has no attribute 'ready_i'
+    @unittest.expectedFailure
     def test_pipe_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 79bc89c1b4b1bb912f3f2380f63ee9814469eb36..40daf8bad1e9730479c27a064829baa6f0f5b9d4 100644 (file)
@@ -16,6 +16,8 @@ def rsqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'NextControl' object has no attribute 'ready_i'
+    @unittest.expectedFailure
     def test_pipe_rsqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 8)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_rsqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 8)
         # don't forget to initialize opcode; don't use magic numbers
@@ -23,6 +25,8 @@ class TestDivPipe(unittest.TestCase):
         runfp(dut, 16, "test_fprsqrt_pipe_fp16", Float16, rsqrt,
               single_op=True, opcode=opcode, n_vals=100, cancel=True)
 
         runfp(dut, 16, "test_fprsqrt_pipe_fp16", Float16, rsqrt,
               single_op=True, opcode=opcode, n_vals=100, cancel=True)
 
+    # FIXME: AttributeError: 'NextControl' object has no attribute 'ready_i'
+    @unittest.expectedFailure
     def test_pipe_rsqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 8)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_rsqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 8)
         # don't forget to initialize opcode; don't use magic numbers
index f02779de59581d920372f43b9bd3c338c4452c1b..69707e48255133054c8309016f624d15b3d14820 100644 (file)
@@ -18,6 +18,8 @@ def rsqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_rsqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 8)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_rsqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 8)
         # don't forget to initialize opcode; don't use magic numbers
index fa74ece2755fa75db14a2ac770a54b07cf79bf16..fb4ceb3e52cc14a37a922eb45d9d1b70b5a04980 100644 (file)
@@ -18,6 +18,8 @@ def rsqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_rsqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_rsqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 61e2e68efdef2672876fb125cc575e8393ff7004..73ff69fb493164e4840bd9d2a96a47fc77fd8d7a 100644 (file)
@@ -14,6 +14,8 @@ def sqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
@@ -21,6 +23,8 @@ class TestDivPipe(unittest.TestCase):
         runfp(dut, 16, "test_fpsqrt_pipe_fp16", Float16, sqrt,
               single_op=True, opcode=opcode, n_vals=100)
 
         runfp(dut, 16, "test_fpsqrt_pipe_fp16", Float16, sqrt,
               single_op=True, opcode=opcode, n_vals=100)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
@@ -28,6 +32,8 @@ class TestDivPipe(unittest.TestCase):
         runfp(dut, 32, "test_fpsqrt_pipe_fp32", Float32, sqrt,
               single_op=True, opcode=opcode, n_vals=100)
 
         runfp(dut, 32, "test_fpsqrt_pipe_fp32", Float32, sqrt,
               single_op=True, opcode=opcode, n_vals=100)
 
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 613823227e0eef1f92c6162a061a591d393bd5ce..a13b277adcff2d78026f66b166aca1110f0cbd38 100644 (file)
@@ -16,6 +16,8 @@ def sqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp16(self):
         dut = FPDIVMuxInOut(16, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 65caf698fc5f6300e89a39e6adb66e3caca26b04..4465787fee28cf7147f904d11712c103a1f0d91b 100644 (file)
@@ -16,6 +16,8 @@ def sqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp32(self):
         dut = FPDIVMuxInOut(32, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 35aa88a86ac13ca933d3345a434cb51c19ea59c8..b18ae5d53a29a06ca575793e7fb21b6a769307f7 100644 (file)
@@ -16,6 +16,8 @@ def sqrt(x):
 
 
 class TestDivPipe(unittest.TestCase):
 
 
 class TestDivPipe(unittest.TestCase):
+    # FIXME: AttributeError: 'PrevControl' object has no attribute 'valid_i'
+    @unittest.expectedFailure
     def test_pipe_sqrt_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
     def test_pipe_sqrt_fp64(self):
         dut = FPDIVMuxInOut(64, 4)
         # don't forget to initialize opcode; don't use magic numbers
index 518555b3b619798dcbc6127f4aeabf2da8df2f07..95425c0315d1d3e34e8279d2a4989312a501d306 100644 (file)
@@ -268,6 +268,7 @@ class TestAddMod(Elaboratable):
 
 
 class TestMux(unittest.TestCase):
 
 
 class TestMux(unittest.TestCase):
+    @unittest.expectedFailure  # FIXME: test fails in CI
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
@@ -345,6 +346,7 @@ class TestMux(unittest.TestCase):
 
 
 class TestCat(unittest.TestCase):
 
 
 class TestCat(unittest.TestCase):
+    @unittest.expectedFailure  # FIXME: test fails in CI
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
@@ -441,6 +443,7 @@ class TestCat(unittest.TestCase):
 
 
 class TestRepl(unittest.TestCase):
 
 
 class TestRepl(unittest.TestCase):
+    @unittest.expectedFailure  # FIXME: test fails in CI
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
     def test(self):
         width = 16
         part_mask = Signal(3)  # divide into 4-bits
@@ -650,6 +653,7 @@ class TestAssign(unittest.TestCase):
                 traces=traces):
             sim.run()
 
                 traces=traces):
             sim.run()
 
+    @unittest.expectedFailure  # FIXME: test fails in CI
     def test(self):
         for out_width in [16, 24, 8]:
             for sign in [True, False]:
     def test(self):
         for out_width in [16, 24, 8]:
             for sign in [True, False]:
@@ -997,7 +1001,7 @@ class TestSimdSignal(unittest.TestCase):
 
 
 # TODO: adapt to SimdSignal. perhaps a different style?
 
 
 # TODO: adapt to SimdSignal. perhaps a different style?
-'''
+r'''
     from nmigen.tests.test_hdl_ast import SignedEnum
     def test_matches(self)
         s = Signal(4)
     from nmigen.tests.test_hdl_ast import SignedEnum
     def test_matches(self)
         s = Signal(4)
index 1da4e3720f40bf1096526702103e2ca9590bed19..2a295013aa21a95fa1aa4be8f08460ba4a6fc4e5 100644 (file)
@@ -2,7 +2,7 @@
 # SPDX-License-Identifier: LGPL-2.1-or-later
 # See Notices.txt for copyright information
 
 # SPDX-License-Identifier: LGPL-2.1-or-later
 # See Notices.txt for copyright information
 
-from nmigen import Signal, Module, Elaboratable, Mux, Cat, Shape, Repl
+from nmigen import Signal, Module, Elaboratable, Mux, Cat, Shape, Repl, Value
 from nmigen.back.pysim import Simulator, Delay, Settle
 from nmigen.cli import rtlil
 
 from nmigen.back.pysim import Simulator, Delay, Settle
 from nmigen.cli import rtlil
 
@@ -47,6 +47,7 @@ class TestCatMod(Elaboratable):
         return m
 
 
         return m
 
 
+@unittest.skipUnless(hasattr(Value, "__Cat__"), "missing nmigen simd support")
 class TestCat(unittest.TestCase):
     def test(self):
         width = 16
 class TestCat(unittest.TestCase):
     def test(self):
         width = 16
index a52349fc7b27c5d240509dc154b546c33d518c67..7d2d89acc01b8cda759858bf34d88b8e6557b887 100644 (file)
@@ -2,6 +2,7 @@
 # SPDX-License-Identifier: LGPL-2.1-or-later
 # See Notices.txt for copyright information
 
 # SPDX-License-Identifier: LGPL-2.1-or-later
 # See Notices.txt for copyright information
 
+from contextlib import contextmanager
 from ieee754.part_mul_add.multiply import \
     (PartitionPoints, PartitionedAdder, AddReduce,
      Mul8_16_32_64, OP_MUL_LOW, OP_MUL_SIGNED_HIGH,
 from ieee754.part_mul_add.multiply import \
     (PartitionPoints, PartitionedAdder, AddReduce,
      Mul8_16_32_64, OP_MUL_LOW, OP_MUL_SIGNED_HIGH,
@@ -23,14 +24,16 @@ def create_ilang(dut, traces, test_name):
         f.write(vl)
 
 
         f.write(vl)
 
 
+@contextmanager
 def create_simulator(module: Any,
                      traces: List[Signal],
 def create_simulator(module: Any,
                      traces: List[Signal],
-                     test_name: str) -> Simulator:
+                     test_name: str):
     create_ilang(module, traces, test_name)
     create_ilang(module, traces, test_name)
-    return Simulator(module,
-                     vcd_file=open(test_name + ".vcd", "w"),
-                     gtkw_file=open(test_name + ".gtkw", "w"),
-                     traces=traces)
+    sim = Simulator(module)
+    with sim.write_vcd(vcd_file=open(test_name + ".vcd", "w"),
+                       gtkw_file=open(test_name + ".gtkw", "w"),
+                       traces=traces):
+        yield sim
 
 
 AsyncProcessCommand = Union[Delay, Tick, Passive, Assign, Value]
 
 
 AsyncProcessCommand = Union[Delay, Tick, Passive, Assign, Value]
@@ -281,54 +284,71 @@ class TestAddReduce(unittest.TestCase):
                               register_levels=repr(register_levels)):
                 self.subtest_file(input_count, register_levels)
 
                               register_levels=repr(register_levels)):
                 self.subtest_file(input_count, register_levels)
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_empty(self) -> None:
         self.subtest_register_levels([])
 
     def test_empty(self) -> None:
         self.subtest_register_levels([])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0(self) -> None:
         self.subtest_register_levels([0])
 
     def test_0(self) -> None:
         self.subtest_register_levels([0])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_1(self) -> None:
         self.subtest_register_levels([1])
 
     def test_1(self) -> None:
         self.subtest_register_levels([1])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_2(self) -> None:
         self.subtest_register_levels([2])
 
     def test_2(self) -> None:
         self.subtest_register_levels([2])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_3(self) -> None:
         self.subtest_register_levels([3])
 
     def test_3(self) -> None:
         self.subtest_register_levels([3])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_4(self) -> None:
         self.subtest_register_levels([4])
 
     def test_4(self) -> None:
         self.subtest_register_levels([4])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_5(self) -> None:
         self.subtest_register_levels([5])
 
     def test_5(self) -> None:
         self.subtest_register_levels([5])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0(self) -> None:
         self.subtest_register_levels([0])
 
     def test_0(self) -> None:
         self.subtest_register_levels([0])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_1(self) -> None:
         self.subtest_register_levels([0, 1])
 
     def test_0_1(self) -> None:
         self.subtest_register_levels([0, 1])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_1_2(self) -> None:
         self.subtest_register_levels([0, 1, 2])
 
     def test_0_1_2(self) -> None:
         self.subtest_register_levels([0, 1, 2])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_1_2_3(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3])
 
     def test_0_1_2_3(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_1_2_3_4(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3, 4])
 
     def test_0_1_2_3_4(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3, 4])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_1_2_3_4_5(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3, 4, 5])
 
     def test_0_1_2_3_4_5(self) -> None:
         self.subtest_register_levels([0, 1, 2, 3, 4, 5])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_2(self) -> None:
         self.subtest_register_levels([0, 2])
 
     def test_0_2(self) -> None:
         self.subtest_register_levels([0, 2])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_3(self) -> None:
         self.subtest_register_levels([0, 3])
 
     def test_0_3(self) -> None:
         self.subtest_register_levels([0, 3])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_4(self) -> None:
         self.subtest_register_levels([0, 4])
 
     def test_0_4(self) -> None:
         self.subtest_register_levels([0, 4])
 
+    @unittest.expectedFailure  # FIXME: NameError: name 'pspec' is not defined
     def test_0_5(self) -> None:
         self.subtest_register_levels([0, 5])
 
     def test_0_5(self) -> None:
         self.subtest_register_levels([0, 5])
 
@@ -528,7 +548,10 @@ class TestMul8_16_32_64(unittest.TestCase):
                  module.output]
         ports.extend(module.part_ops)
         ports.extend(module.part_pts.values())
                  module.output]
         ports.extend(module.part_ops)
         ports.extend(module.part_pts.values())
-        with create_simulator(module, ports, file_name) as sim:
+        m = Module()
+        m.submodules += module
+        m.d.sync += Signal().eq(0)  # ensure sync domain is created
+        with create_simulator(m, ports, file_name) as sim:
             def process(gen_or_check: GenOrCheck) -> AsyncProcessGenerator:
                 for a_signed in False, True:
                     for b_signed in False, True:
             def process(gen_or_check: GenOrCheck) -> AsyncProcessGenerator:
                 for a_signed in False, True:
                     for b_signed in False, True: