scc_info: detect incorrect initial state

* spot/twaalgos/sccinfo.cc: Here.
* tests/python/sccinfo.py: Test it.
This commit is contained in:
Alexandre Duret-Lutz 2017-12-22 17:23:10 +01:00
parent 31ccab026b
commit 904cfb27fa
2 changed files with 11 additions and 0 deletions

View file

@ -22,6 +22,12 @@ import spot
a = spot.translate('(Ga -> Gb) W c')
try:
si = spot.scc_info(a, 10)
exit(2)
except RuntimeError as e:
assert "initial state does not exist" in str(e)
si = spot.scc_info(a)
n = si.scc_count()
assert n == 4