genltl: move all formula generation code to spot/gen/
Fixes #254. * spot/gen/formulas.cc, spot/gen/formulas.hh: New files. * spot/gen/Makefile.am: Add them. * spot/Makefile.am: Fix build order. * bin/genltl.cc: Move most code to the above files and adjust. * bin/Makefile.am: Link genltl with libspotgen. * doc/org/arch.tex: Adjust picture to show that genltl uses libspotgen. * python/spot/gen.i: Include formulas.hh. * tests/python/gen.py: Make sure genltl() and ltl_pattern_name() can be called.
This commit is contained in:
parent
52af3948d6
commit
8939e0dd50
9 changed files with 1495 additions and 1411 deletions
|
|
@ -37,3 +37,22 @@ except RuntimeError as e:
|
|||
assert 'positive argument' in str(e)
|
||||
else:
|
||||
exit(2)
|
||||
|
||||
f = gen.genltl(gen.AND_F, 3)
|
||||
assert f.size() == 3
|
||||
assert gen.ltl_pattern_name(gen.AND_F) == "and-f"
|
||||
|
||||
try:
|
||||
gen.genltl(1000, 3)
|
||||
except RuntimeError as e:
|
||||
assert 'unsupported pattern' in str(e)
|
||||
else:
|
||||
exit(2)
|
||||
|
||||
try:
|
||||
gen.genltl(gen.OR_G, -10)
|
||||
except RuntimeError as e:
|
||||
assert 'or-g' in str(e)
|
||||
assert 'positive' in str(e)
|
||||
else:
|
||||
exit(2)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue