Skip to content

Commit eb01891

Browse files
committed
Test external SAT back-end
The test uses Z3 as this is a tool we expect to be installed in other regression tests anyway.
1 parent ca038c6 commit eb01891

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
CORE gcc-only
2+
main.c
3+
--external-sat-solver ./z3-wrapper.sh --trace
4+
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
7+
--
8+
^warning: ignoring
9+
--
10+
This test is marked "gcc-only" as resolving ./ won't work with Windows.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
#!/bin/sh
2+
3+
# handle output by older Z3 versions where the output was not compatible with
4+
# current SAT solvers
5+
6+
z3 $1 2>&1 | \
7+
perl -n -e '
8+
print "s ".uc($1)."ISFIABLE\n" if(/^((un)?sat)\s*$/);
9+
print "v $_\n" if(/^-?\d+/);
10+
print "$_\n" if(/^[sv]\s+/);' 2>&1

0 commit comments

Comments
 (0)