Skip to content

Commit 10fd5cf

Browse files
committed
CI: run testsuite with -Werror.
1 parent c6150d0 commit 10fd5cf

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

.github/workflows/main.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ jobs:
3333
- name: Run tests
3434
run: |
3535
export NMIGEN_USE_YOSYS=builtin YOSYS=yowasp-yosys SBY=yowasp-sby SMTBMC=yowasp-yosys-smtbmc
36+
export PYTHONWARNINGS=error
3637
python -m coverage run -m unittest
3738
codecov
3839
document:

tests/utils.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,10 @@ def assertFormal(self, spec, mode="bmc", depth=1):
7474
script=script,
7575
rtlil=rtlil.convert(Fragment.get(spec, platform="formal"))
7676
)
77-
with subprocess.Popen([require_tool("sby"), "-f", "-d", spec_name], cwd=spec_dir,
78-
universal_newlines=True,
79-
stdin=subprocess.PIPE, stdout=subprocess.PIPE) as proc:
77+
with subprocess.Popen(
78+
[require_tool("sby"), "-f", "-d", spec_name],
79+
cwd=spec_dir, env={**os.environ, "PYTHONWARNINGS":"ignore"},
80+
universal_newlines=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE) as proc:
8081
stdout, stderr = proc.communicate(config)
8182
if proc.returncode != 0:
8283
self.fail("Formal verification failed:\n" + stdout)

0 commit comments

Comments
 (0)