Commit a9a375cc authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz

tests: git rid of all the tool=tool assignents

Our use of
  ltl2tgba=ltl2tgba
  autfilt=autfilt
  ...
all over the test cases comes from the time where those tools were not
in PATH and we actually had something like
  ltl2tgba=../../bin/ltl2tgba
  autfilt=../../bin/autfilt

But today that is useless, and we prefer to write ltl2tgba rather than
$ltl2tgba, so let's remove this old cruft.

* tests/core/basimul.test, tests/core/det.test, tests/core/lbt.test,
tests/core/lenient.test, tests/core/ltl2dstar.test,
tests/core/ltl2dstar2.test, tests/core/ltl2dstar3.test,
tests/core/ltl2dstar4.test, tests/core/ltlcross2.test,
tests/core/ltlcross3.test, tests/core/ltlcross4.test,
tests/core/ltlcrossce2.test, tests/core/ltldo.test,
tests/core/ltlfilt.test, tests/core/optba.test,
tests/core/prodor.test, tests/core/rand.test,
tests/core/randomize.test, tests/core/remfin.test,
tests/core/satmin.test, tests/core/sbacc.test,
tests/core/strength.test, tests/core/stutter-ltl.test,
tests/core/stutter-tgba.test, tests/core/unabbrevwm.test,
tests/core/unambig.test: Get rid of all tool=tool assignments.
parent a31ba7ff
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2013, 2014 Laboratoire de Recherche et Développement de
# l'Epita (LRDE).
# Copyright (C) 2013, 2014, 2017 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
#
......@@ -22,9 +22,6 @@
set -e
ltl2tgba=ltl2tgba
# This bug was found while working on the state-based acceptance
# output for the LBTT format. Using ba-simul=2 causes reverse
# simulation to be applied to the BA automaton obtained after
......@@ -60,15 +57,15 @@ ltlcross --seed=0 --products=5 --json=out.json \
-f '!p2 & (Fp5 R (((p0 U p1) & (p5 | p1)) | (!p5 & (!p0 R !p1))))' \
-f '! ((p0 /\ p4) <-> ! ((! p0 U (p0 W p4)) /\ (X p5 -> ([] p3 /\ p5))))' \
-f '(X <> (<> X p0 /\ X (p5 <-> p0)) W (p3 W p0))' \
"$ltl2tgba --ba --high --lbtt=t -x ba-simul=0 %f >%T" \
"$ltl2tgba --ba --high --lbtt=t -x ba-simul=1 %f >%T" \
"$ltl2tgba --ba --high --lbtt=t -x ba-simul=2 %f >%T" \
"$ltl2tgba --ba --high --lbtt=t -x ba-simul=3 %f >%T" \
"$ltl2tgba --ba --high --lbtt -x ba-simul=0 %f >%T" \
"$ltl2tgba --ba --high --lbtt -x ba-simul=1 %f >%T" \
"$ltl2tgba --ba --high --lbtt -x ba-simul=2 %f >%T" \
"$ltl2tgba --ba --high --lbtt -x ba-simul=3 %f >%T" \
"$ltl2tgba --ba --high --spin -x ba-simul=0 %f >%N" \
"$ltl2tgba --ba --high --spin -x ba-simul=1 %f >%N" \
"$ltl2tgba --ba --high --spin -x ba-simul=2 %f >%N" \
"$ltl2tgba --ba --high --spin -x ba-simul=3 %f >%N"
"ltl2tgba --ba --high --lbtt=t -x ba-simul=0 %f >%T" \
"ltl2tgba --ba --high --lbtt=t -x ba-simul=1 %f >%T" \
"ltl2tgba --ba --high --lbtt=t -x ba-simul=2 %f >%T" \
"ltl2tgba --ba --high --lbtt=t -x ba-simul=3 %f >%T" \
"ltl2tgba --ba --high --lbtt -x ba-simul=0 %f >%T" \
"ltl2tgba --ba --high --lbtt -x ba-simul=1 %f >%T" \
"ltl2tgba --ba --high --lbtt -x ba-simul=2 %f >%T" \
"ltl2tgba --ba --high --lbtt -x ba-simul=3 %f >%T" \
"ltl2tgba --ba --high --spin -x ba-simul=0 %f >%N" \
"ltl2tgba --ba --high --spin -x ba-simul=1 %f >%N" \
"ltl2tgba --ba --high --spin -x ba-simul=2 %f >%N" \
"ltl2tgba --ba --high --spin -x ba-simul=3 %f >%N"
......@@ -21,8 +21,6 @@
. ./defs
set -e
ltl2tgba=ltl2tgba
cat >formulas <<'EOF'
1,13,X((a M F((!b & !c) | (b & c))) W (G!c U b))
1,5,X(((a & b) R (!a U !c)) R b)
......@@ -56,7 +54,7 @@ cat >formulas <<'EOF'
1,4,G(G!a | F!c | G!b)
EOF
$ltl2tgba -x tba-det --det --stats '%d,%s,%f' -F formulas/3 > out
ltl2tgba -x tba-det --det --stats '%d,%s,%f' -F formulas/3 > out
diff formulas out
cat >in.hoa <<'EOF'
......
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2013, 2016 Laboratoire de Recherche et
# Copyright (C) 2013, 2016, 2017 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
......@@ -21,10 +21,6 @@
. ./defs
set -e
ltlfilt=ltlfilt
randltl=randltl
genltl=genltl
# Some example formulas taken from Ruediger Ehlers's dbaminimizer
# http://react.cs.uni-saarland.de/tools/dbaminimizer
# which are expected to be processed by ltl2dstar.
......@@ -85,18 +81,18 @@ U p0 & | p0 p5 p1
EOF
# More examples randomly generated
$randltl -l -n 100 a p1 "X" "U" "U12" >> formulas
randltl -l -n 100 a p1 "X" "U" "U12" >> formulas
# Some examples from scalables formulas
$genltl --rv-counter=1..10 --go-theta=1..10 -l >> formulas
genltl --rv-counter=1..10 --go-theta=1..10 -l >> formulas
count=`wc -l < formulas`
test $count -eq 168
run 0 $ltlfilt --lbt-input formulas > formulas.2
run 0 $ltlfilt -l formulas.2 > formulas.3
run 0 $ltlfilt -l --lbt-input formulas > formulas.4
run 0 ltlfilt --lbt-input formulas > formulas.2
run 0 ltlfilt -l formulas.2 > formulas.3
run 0 ltlfilt -l --lbt-input formulas > formulas.4
test `wc -l < formulas.2` -eq 168
test `wc -l < formulas.3` -eq 168
test `wc -l < formulas.4` -eq 168
......@@ -104,15 +100,15 @@ test `wc -l < formulas.4` -eq 168
# The --csv-escape option is now obsolete and replaced by double
# quotes in the format string. So eventually the first two lines
# should disappear.
run 0 $ltlfilt formulas.2 --csv-escape --format='%L,%f' > formulas.5
run 0 $ltlfilt formulas.5/2 --csv-escape --format='%L,%f' > formulas.6
run 0 $ltlfilt formulas.2 --format='%L,"%f"' > formulas.5a
run 0 $ltlfilt formulas.5/2 --format='%L,"%f"' > formulas.6a
run 0 ltlfilt formulas.2 --csv-escape --format='%L,%f' > formulas.5
run 0 ltlfilt formulas.5/2 --csv-escape --format='%L,%f' > formulas.6
run 0 ltlfilt formulas.2 --format='%L,"%f"' > formulas.5a
run 0 ltlfilt formulas.5/2 --format='%L,"%f"' > formulas.6a
cmp formulas.5 formulas.6
cmp formulas.5 formulas.5a
cmp formulas.5a formulas.6a
# Make sure ltl2dstar-style litterals always get quoted.
test "`$ltlfilt -l --lbt-input -f 'G F a'`" = 'G F "a"'
test "`ltlfilt -l --lbt-input -f 'G F a'`" = 'G F "a"'
# Original lbt-style litterals are unquoted.
test "`$ltlfilt -l --lbt-input -f 'G F p42'`" = 'G F p42'
test "`ltlfilt -l --lbt-input -f 'G F p42'`" = 'G F p42'
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2012 Laboratoire de Recherche et Développement de
# Copyright (C) 2012, 2017 Laboratoire de Recherche et Développement de
# l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
......@@ -22,8 +22,6 @@
set -e
ltlfilt=ltlfilt
cat >input <<EOF
(a < b) U (b == c - 1)
((a < b) U {b == c - 1})
......@@ -48,10 +46,10 @@ cat >expected <<EOF
Xa
EOF
run 0 $ltlfilt --lenient input > output
run 0 ltlfilt --lenient input > output
cmp output expected
run 2 $ltlfilt --lenient -f 'F( )' 2> stderr
grep 'unexpected empty block' stderr
\ No newline at end of file
run 2 ltlfilt --lenient -f 'F( )' 2> stderr
grep 'unexpected empty block' stderr
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2013, 2014, 2015, 2016 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
# Copyright (C) 2013-2017 Laboratoire de Recherche et Développement de
# l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
#
......@@ -28,16 +28,9 @@ set -e
# Skip this test if ltl2dstar is not installed.
(ltl2dstar --version) || exit 77
ltlfilt=ltlfilt
ltl2tgba=ltl2tgba
ltlcross=ltlcross
randltl=randltl
ltlfilt=ltlfilt
dstar2tgba=dstar2tgba
$ltlfilt -f 'a U b' -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-s - - |
$dstar2tgba --stats '%s %e %t %a %d' |
ltlfilt -f 'a U b' -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-s - - |
dstar2tgba --stats '%s %e %t %a %d' |
tee out
test "`cat out`" = '2 3 7 1 1'
......@@ -45,33 +38,33 @@ test "`cat out`" = '2 3 7 1 1'
RAB=--automata=rabin
STR=--automata=streett
$randltl -n 15 a b | $ltlfilt --nnf --remove-wm |
$ltlcross -F - -f 'GFa & GFb & GFc' -f '(GFa -> GFb) & (GFc -> GFd)' \
randltl -n 15 a b | ltlfilt --nnf --remove-wm |
ltlcross -F - -f 'GFa & GFb & GFc' -f '(GFa -> GFb) & (GFc -> GFd)' \
--timeout=30 \
"$ltl2tgba -s %f >%N" \
"ltl2dstar $RAB --output=nba --ltl2nba=spin:$ltl2tgba@-s %L %T" \
"ltl2dstar $RAB --ltl2nba=spin:$ltl2tgba@-s %L %D" \
"ltl2dstar $RAB --ltl2nba=spin:$ltl2tgba@-s %L - | $dstar2tgba --low -s >%N" \
"ltl2dstar $STR --output=nba --ltl2nba=spin:$ltl2tgba@-s %L %T" \
"ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L - | $dstar2tgba --low -s >%N" \
"ltl2tgba -s %f >%N" \
"ltl2dstar $RAB --output=nba --ltl2nba=spin:ltl2tgba@-s %L %T" \
"ltl2dstar $RAB --ltl2nba=spin:ltl2tgba@-s %L %D" \
"ltl2dstar $RAB --ltl2nba=spin:ltl2tgba@-s %L - | dstar2tgba --low -s >%N" \
"ltl2dstar $STR --output=nba --ltl2nba=spin:ltl2tgba@-s %L %T" \
"ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L - | dstar2tgba --low -s >%N" \
--csv=out.csv
# A bug in ltlcross <=1.2.5 caused it to not use the complement of the
# negative automaton.
$ltlcross -f 'GFa' --verbose \
"ltl2dstar $RAB --ltl2nba=spin:$ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L %D" 2>err
ltlcross -f 'GFa' --verbose \
"ltl2dstar $RAB --ltl2nba=spin:ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L %D" 2>err
test `grep -c 'info: check_empty.*Comp' err` = 2
$ltlcross -f 'FGa' --verbose \
"ltl2dstar $RAB --ltl2nba=spin:$ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L %D" 2>err
ltlcross -f 'FGa' --verbose \
"ltl2dstar $RAB --ltl2nba=spin:ltl2tgba@-s %L %D" \
"ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L %D" 2>err
test `grep -c 'info: check_empty.*Comp' err` = 2
# Make sure ltldo preserve the Rabin acceptance by default
ltldo \
"ltl2dstar --ltl2nba=spin:$ltl2tgba@-s --output-format=hoa %L %O" \
"ltl2dstar --ltl2nba=spin:ltl2tgba@-s --output-format=hoa %L %O" \
-f 'GFa -> GFb' -Hi > out.hoa
cat >expected <<EOF
HOA: v1
......
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2013, 2015, 2016 Laboratoire de Recherche et
# Copyright (C) 2013, 2015-2017 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
......@@ -28,33 +28,27 @@ set -e
# Skip this test if ltl2dstar is not installed.
(ltl2dstar --version) || exit 77
ltlfilt=ltlfilt
ltl2tgba=ltl2tgba
dstar2tgba=dstar2tgba
randltl=randltl
# Make sure all recurrence formulas are translated into deterministic
# Büchi automata by the DRA->TGBA converter.
# (Note that ltl2tgba is not called with -D when want to make
# sure we get a deterministic output even if the automaton generated
# by Spot initially was non-deterministic)
$randltl -n -1 a b --tree-size=5..15 |
$ltlfilt --syntactic-recurrence --remove-wm -r -u \
randltl -n -1 a b --tree-size=5..15 |
ltlfilt --syntactic-recurrence --remove-wm -r -u \
--size-min=4 --size-max=15 --relabel=abc |
head -n 20 > formulas
$randltl -n -1 a b --tree-size=5..15 |
$ltlfilt -v --obligation |
$ltlfilt --syntactic-recurrence --remove-wm -r -u --size=4..15 --relabel=abc |
randltl -n -1 a b --tree-size=5..15 |
ltlfilt -v --obligation |
ltlfilt --syntactic-recurrence --remove-wm -r -u --size=4..15 --relabel=abc |
head -n 20 >> formulas
while read f; do
$ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-s - foo
ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-s - foo
echo "$f"
det=`$dstar2tgba foo --stats '%d'`
det=`dstar2tgba foo --stats '%d'`
test $det -eq 1;
done < formulas
......@@ -62,16 +56,16 @@ echo ==========================
# For obligation formulas, the output of dstar2tgba should
# have the same size as the input when option -D is used.
$randltl -n -1 a b --tree-size=5..15 |
$ltlfilt --obligation --size=4..15 --relabel=abc --remove-wm -r -u |
randltl -n -1 a b --tree-size=5..15 |
ltlfilt --obligation --size=4..15 --relabel=abc --remove-wm -r -u |
head -n 20 > formulas
while read f; do
expected=`$ltl2tgba "$f" -BD --stats '%s %e 1 %d'`
$ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-Ds - foo
expected=`ltl2tgba "$f" -BD --stats '%s %e 1 %d'`
ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-Ds - foo
echo "$f"
output=`$dstar2tgba foo -BD --stats '%s %e %d 1'`
output=`dstar2tgba foo -BD --stats '%s %e %d 1'`
# the '1 %d' matching '%d 1' makes sure input and output are deterministic.
test "$output" = "$expected";
done < formulas
......@@ -90,9 +84,9 @@ FGa & FGb
EOF
while read f; do
$ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-s - foo
ltlfilt -f "$f" -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-s - foo
echo "$f"
det=`$dstar2tgba foo --stats '%d'`
det=`dstar2tgba foo --stats '%d'`
test $det -eq 0;
done < formulas
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2015 Laboratoire de Recherche et
# Copyright (C) 2015, 2017 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
......@@ -26,23 +26,16 @@ set -e
# Skip this test if ltl2dstar is not installed.
(ltl2dstar --version) || exit 77
ltlfilt=ltlfilt
ltl2tgba=ltl2tgba
ltlcross=ltlcross
randltl=randltl
ltlfilt=ltlfilt
dstar2tgba=dstar2tgba
RAB='--automata=rabin --output-format=hoa'
STR='--automata=streett --output-format=hoa'
# Run ltlcross without product, because this requires too much memory.
$randltl -n 25 a b | $ltlfilt --remove-wm |
$ltlcross -F- -f 'GFa & GFb & GFc' -f '(GFa -> GFb) & (GFc -> GFd)' \
randltl -n 25 a b | ltlfilt --remove-wm |
ltlcross -F- -f 'GFa & GFb & GFc' -f '(GFa -> GFb) & (GFc -> GFd)' \
--timeout=30 --verbose --csv=out.csv --products=0 \
"$ltl2tgba -s %f >%N" \
"ltl2dstar $RAB --ltl2nba=spin:$ltl2tgba@-s %L %H" \
"ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L %H"
"ltl2tgba -s %f >%N" \
"ltl2dstar $RAB --ltl2nba=spin:ltl2tgba@-s %L %H" \
"ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L %H"
grep '"in_type"' out.csv && exit 1
exit 0
#!/bin/sh
# -*- coding: utf-8 -*-
# Copyright (C) 2013, 2014, 2015 Laboratoire de Recherche et
# Copyright (C) 2013, 2014, 2015, 2017 Laboratoire de Recherche et
# Développement de l'Epita (LRDE).
#
# This file is part of Spot, a model checking library.
......@@ -28,42 +28,34 @@ set -e
# Skip this test if ltl2dstar is not installed.
(ltl2dstar --version) || exit 77
ltlfilt=ltlfilt
ltl2tgba=ltl2tgba
ltlcross=ltlcross
randltl=randltl
autfilt=autfilt
ltldo=ltldo
STR='--automata=streett --output-format=hoa'
$ltlfilt -f '(GFa -> GFb) & (GFc -> GFd)' -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-s $STR - - |
$autfilt --tgba --stats '%S %E %A %s %e %t %a %d' |
ltlfilt -f '(GFa -> GFb) & (GFc -> GFd)' -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-s $STR - - |
autfilt --tgba --stats '%S %E %A %s %e %t %a %d' |
tee out
test "`cat out`" = '9 144 4 25 149 416 2 0'
$ltlfilt -f '(GFa -> GFb) & (GFc -> GFd)' -l |
ltl2dstar --ltl2nba=spin:$ltl2tgba@-s $STR - - |
SPOT_STREETT_CONV_MIN=1 $autfilt --tgba --stats '%S %E %A %s %e %t %a %d' |
ltlfilt -f '(GFa -> GFb) & (GFc -> GFd)' -l |
ltl2dstar --ltl2nba=spin:ltl2tgba@-s $STR - - |
SPOT_STREETT_CONV_MIN=1 autfilt --tgba --stats '%S %E %A %s %e %t %a %d' |
tee out
test "`cat out`" = '9 144 4 25 218 482 2 0'
LTL2DSTAR="ltl2dstar $STR --ltl2nba=spin:$ltl2tgba@-s %L"
LTL2DSTAR="ltl2dstar $STR --ltl2nba=spin:ltl2tgba@-s %L"
# Generate 50 formulas for which the streett automaton has at least 3
# acceptance sets.
$randltl --ltl-priorities=W=0,M=0 -n 1000 3 |
$ltldo "$LTL2DSTAR ->%O" -F- --name=%f -H | tee streett |
$autfilt --acc-set=3.. --stats=%M | head -n 50 > formulas
randltl --ltl-priorities=W=0,M=0 -n 1000 3 |
ltldo "$LTL2DSTAR ->%O" -F- --name=%f -H | tee streett |
autfilt --acc-set=3.. --stats=%M | head -n 50 > formulas
# Add 50 formulas that use less acceptance sets
$autfilt streett --acc-set=0..2 --stats=%M | head -n 50 >> formulas
autfilt streett --acc-set=0..2 --stats=%M | head -n 50 >> formulas
$ltlcross -F formulas --timeout=30 \
"$ltl2tgba -H %f >%O" \
ltlcross -F formulas --timeout=30 \
"ltl2tgba -H %f >%O" \
"$LTL2DSTAR %O" \
"$LTL2DSTAR - | SPOT_STREETT_CONV_MIN=0 $autfilt --tgba -H >%O" \
"$LTL2DSTAR - | SPOT_STREETT_CONV_MIN=1 $autfilt --tgba -H >%O" \
"$LTL2DSTAR - | SPOT_STREETT_CONV_MIN=0 autfilt --tgba -H >%O" \
"$LTL2DSTAR - | SPOT_STREETT_CONV_MIN=1 autfilt --tgba -H >%O" \
--csv=out.csv
......@@ -21,28 +21,26 @@
. ./defs
set -e
ltl2tgba=ltl2tgba
randltl -P -n 100 p1 p2 p3 p4 p5 p6 --tree-size 5..15 --seed=314 |
ltlcross --products=3 --timeout=60 \
"$ltl2tgba --lbtt --any --low %f > %T" \
"$ltl2tgba --lbtt --any --medium %f > %T" \
"$ltl2tgba --hoa --any --high %f > %H" \
"$ltl2tgba --lbtt --deterministic --low %f > %T" \
"$ltl2tgba --lbtt --deterministic --medium %f > %T" \
"$ltl2tgba --lbtt --deterministic --high %f > %T" \
"$ltl2tgba --lbtt --small --low %f > %T" \
"$ltl2tgba --hoa --small --medium %f > %H" \
"$ltl2tgba --lbtt --small --high %f > %T" \
"$ltl2tgba --lbtt -x comp-susp --small %f >%T" \
"$ltl2tgba --lbtt -x comp-susp,!skel-wdba --small %f >%T" \
"$ltl2tgba --lbtt -x comp-susp,early-susp --small %f >%T" \
"$ltl2tgba --lbtt -x comp-susp,!skel-wdba,!skel-simul --small %f >%T" \
"$ltl2tgba --spin --ba -x degen-lskip=0 %f >%N" \
"$ltl2tgba --lbtt --ba --high %f > %T" \
"$ltl2tgba --spin=6 --ba -x degen-order,degen-lcache=2 --medium %f > %N" \
"$ltl2tgba --hoa -x degen-lcache=3 -BDC %f > %H" \
"$ltl2tgba --lbtt -BC %f > %T" \
"$ltl2tgba --lbtt --unambiguous --low %f > %T" \
"$ltl2tgba --lbtt --unambiguous --high %f > %T" \
"ltl2tgba --lbtt --any --low %f > %T" \
"ltl2tgba --lbtt --any --medium %f > %T" \
"ltl2tgba --hoa --any --high %f > %H" \
"ltl2tgba --lbtt --deterministic --low %f > %T" \
"ltl2tgba --lbtt --deterministic --medium %f > %T" \
"ltl2tgba --lbtt --deterministic --high %f > %T" \
"ltl2tgba --lbtt --small --low %f > %T" \
"ltl2tgba --hoa --small --medium %f > %H" \
"ltl2tgba --lbtt --small --high %f > %T" \
"ltl2tgba --lbtt -x comp-susp --small %f >%T" \
"ltl2tgba --lbtt -x comp-susp,!skel-wdba --small %f >%T" \
"ltl2tgba --lbtt -x comp-susp,early-susp --small %f >%T" \
"ltl2tgba --lbtt -x comp-susp,!skel-wdba,!skel-simul --small %f >%T" \
"ltl2tgba --spin --ba -x degen-lskip=0 %f >%N" \
"ltl2tgba --lbtt --ba --high %f > %T" \
"ltl2tgba --spin=6 --ba -x degen-order,degen-lcache=2 --medium %f > %N" \
"ltl2tgba --hoa -x degen-lcache=3 -BDC %f > %H" \
"ltl2tgba --lbtt -BC %f > %T" \
"ltl2tgba --lbtt --unambiguous --low %f > %T" \
"ltl2tgba --lbtt --unambiguous --high %f > %T" \
--json=output.json --csv=output.csv
......@@ -31,16 +31,14 @@ check_csv()
done)
}
ltl2tgba=ltl2tgba
# Make sure ltlcross quotes formulas correctly
cat >formula <<\EOF
G"a'-'>'b"
FGa
EOF
run 0 ltlcross -F formula --csv=out.csv \
"$ltl2tgba -s %f >%N" \
"$ltl2tgba --lenient -s %s >%N" \
"ltl2tgba -s %f >%N" \
"ltl2tgba --lenient -s %s >%N" \
--verbose 2> error
cat >ceplan <<EOF
info: check_empty P0*N0
......@@ -60,8 +58,8 @@ grep 'info: check_empty' error > ce
diff -u ce ceplan
ltlcross -F formula --csv=out.csv \
--ref "$ltl2tgba -s %f >%N" \
"$ltl2tgba --lenient -s %s >%N" \
--ref "ltl2tgba -s %f >%N" \
"ltl2tgba --lenient -s %s >%N" \
--verbose 2> error
cat >ceplan <<EOF
info: check_empty P0*N1
......@@ -77,8 +75,8 @@ grep 'info: check_empty' error > ce
diff -u ce ceplan
ltlcross -F formula --csv=out.csv \
-D "$ltl2tgba -s %f >%N" \
"$ltl2tgba --lenient -s %s >%N" \
-D "ltl2tgba -s %f >%N" \
"ltl2tgba --lenient -s %s >%N" \
--verbose 2> error
cat >ceplan <<EOF
info: check_empty P0*N0
......@@ -98,8 +96,8 @@ grep 'info: check_empty' error > ce
diff -u ce ceplan
ltlcross -F formula --csv=out.csv \
-D --ref "$ltl2tgba -s %f >%N" \
"$ltl2tgba --lenient -s %s >%N" \
-D --ref "ltl2tgba -s %f >%N" \
"ltl2tgba --lenient -s %s >%N" \
--verbose 2> error
cat >ceplan <<EOF
......@@ -116,16 +114,16 @@ grep 'info: check_empty' error > ce
diff -u ce ceplan
ltlcross -F formula --csv=out.csv \
--ref "$ltl2tgba -s %f >%N" \
--ref "$ltl2tgba --lenient -s %s >%N" \
--ref "ltl2tgba -s %f >%N" \
--ref "ltl2tgba --lenient -s %s >%N" \
--verbose 2> error
grep 'info: check_empty' error && exit 1
run 2 ltlcross "$ltl2tgba -s %f >%N" 'foo bar' 2>stderr -f a
run 2 ltlcross "ltl2tgba -s %f >%N" 'foo bar' 2>stderr -f a
grep 'ltlcross.*no input.*in.*foo bar' stderr
# Make sure non-zero exit codes are reported...
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv 2>stderr
grep '"exit_status"' out.csv
grep '"exit_code"' out.csv
......@@ -134,7 +132,7 @@ test `grep '"exit code",1' out.csv | wc -l` -eq 2
check_csv out.csv
# ... unless --omit-missing is supplied.
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --omit-missing 2>stderr
grep '"exit_status"' out.csv && exit 1
grep '"exit_code"' out.csv && exit 1
......@@ -143,7 +141,7 @@ test `grep '"exit code",1' out.csv | wc -l` -eq 0
check_csv out.csv
# Additional columns should not be an issue
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --strength 2>stderr
grep '"exit_status"' out.csv
grep '"exit_code"' out.csv
......@@ -154,7 +152,7 @@ test `grep 'error:.*returned exit code 1' stderr | wc -l` -eq 2
test `grep '"exit code",1' out.csv | wc -l` -eq 2
check_csv out.csv
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --ambiguous 2>stderr
grep '"exit_status"' out.csv
grep '"exit_code"' out.csv
......@@ -164,7 +162,7 @@ test `grep 'error:.*returned exit code 1' stderr | wc -l` -eq 2
test `grep '"exit code",1' out.csv | wc -l` -eq 2
check_csv out.csv
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --ambiguous --strength 2>stderr
grep '"exit_status"' out.csv
grep '"exit_code"' out.csv
......@@ -219,7 +217,7 @@ test `wc -l < bogous` -eq 1
check_csv out.csv
# Check with --products=5 --automata
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --products=5 --automata 2>stderr
p=`sed 's/[^,]//g;q' out.csv | wc -c`
grep '"exit_status"' out.csv
......@@ -230,7 +228,7 @@ test `grep '"HOA:.*--BODY--.*--END--"' out.csv | wc -l` -eq 2
check_csv out.csv
# ... unless --omit-missing is supplied.
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --omit-missing --products=5 2>stderr
grep '"exit_status"' out.csv && exit 1
grep '"exit_code"' out.csv && exit 1
......@@ -240,7 +238,7 @@ check_csv out.csv
# Check with --products=+5
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --products=+5 --automata 2>stderr
q=`sed 's/[^,]//g;q' out.csv | wc -c`
grep '"exit_status"' out.csv
......@@ -251,7 +249,7 @@ test `grep '"HOA:.*--BODY--.*--END--"' out.csv | wc -l` -eq 2
check_csv out.csv
# ... unless --omit-missing is supplied.
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%N' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%N' \
-f a --csv=out.csv --omit-missing --products=+5 2>stderr
grep '"exit_status"' out.csv && exit 1
grep '"exit_code"' out.csv && exit 1
......@@ -265,7 +263,7 @@ test $q -eq `expr $p + 12`
# Check with Rabin/Streett output
first="should not be erased"
echo "$first" > bug.txt
run 1 ltlcross "$ltl2tgba -s %f >%N" 'false %f >%D' \
run 1 ltlcross "ltl2tgba -s %f >%N" 'false %f >%D' \
-f 'X a' --csv=out.csv --save-bogus='>>bug.txt' 2>stderr
q=`sed 's/[^,]//g;q' out.csv | wc -c`
test $q -eq `expr $p - 1`
......
......@@ -23,17 +23,15 @@ set -e
test -z "$PYTHON" && exit 77
ltl2tgba=ltl2tgba
cat >formulas.txt <<EOF
GFa & GFb
GFa -> GFb
EOF