test: fix example test after commit a7b8ced9.
authorwhitequark <whitequark@whitequark.org>
Thu, 11 Jun 2020 16:29:12 +0000 (16:29 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Fri, 31 Dec 2021 14:08:23 +0000 (14:08 +0000)
nmigen/test/test_examples.py

index 94b93771c6544e4d15344ec36196374d4c689ee5..44211d37309ee4f85224ac6d0517a71dbe854e46 100644 (file)
@@ -8,7 +8,8 @@ from .utils import *
 def example_test(name):
     path = (Path(__file__).parent / ".." / ".." / "examples" / name).resolve()
     def test_function(self):
-        subprocess.check_call([sys.executable, str(path), "generate"], stdout=subprocess.DEVNULL)
+        subprocess.check_call([sys.executable, str(path), "generate", "-t", "v"],
+                              stdout=subprocess.DEVNULL)
     return test_function
 
 
@@ -25,4 +26,9 @@ class ExamplesTestCase(FHDLTestCase):
     test_mem        = example_test("basic/mem.py")
     test_pmux       = example_test("basic/pmux.py")
     test_por        = example_test("basic/por.py")
-    test_uart       = example_test("basic/uart.py")
+
+    def test_uart(self):
+        path = (Path(__file__).parent / ".." / ".." / "examples" / "basic" / "uart.py").resolve()
+        def test_function(self):
+            subprocess.check_call([sys.executable, str(path), "generate"],
+                                  stdout=subprocess.DEVNULL)