randltl: fix option --allow-dups

* bin/randltl.cc: here
* tests/core/rand.test: test it
* NEWS: document it
This commit is contained in:
Maximilien Colange 2018-05-23 10:58:32 +02:00
parent cde0977ef8
commit 1a4117a07f
3 changed files with 11 additions and 1 deletions

2
NEWS
View file

@ -112,6 +112,8 @@ New in spot 2.5.3.dev (not yet released)
- The HOA parser will now accept Alias: declarations that occur - The HOA parser will now accept Alias: declarations that occur
before AP:. before AP:.
- the option --allow-dups of randltl now works properly
New in spot 2.5.3 (2018-04-20) New in spot 2.5.3 (2018-04-20)
Bugs fixed: Bugs fixed:

View file

@ -267,6 +267,7 @@ main(int argc, char** argv)
opts.set("wf", opt_wf); opts.set("wf", opt_wf);
opts.set("seed", opt_seed); opts.set("seed", opt_seed);
opts.set("simplification_level", simplification_level); opts.set("simplification_level", simplification_level);
opts.set("unique", opt_unique);
return opts; return opts;
}(), opt_pL, opt_pS, opt_pB); }(), opt_pL, opt_pS, opt_pB);

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright (C) 2014, 2015, 2017 Laboratoire de Recherche et # Copyright (C) 2014, 2015, 2017, 2018 Laboratoire de Recherche et
# Développement de l'Epita (LRDE). # Développement de l'Epita (LRDE).
# #
# This file is part of Spot, a model checking library. # This file is part of Spot, a model checking library.
@ -138,3 +138,10 @@ diff test-cmp.ltl test-all.ltl
randltl 2 --ltl-prio=X 2>stderr && exit 1 randltl 2 --ltl-prio=X 2>stderr && exit 1
grep 'failed to parse LTL priorities near X' stderr grep 'failed to parse LTL priorities near X' stderr
randltl -L --allow-dups -n2 1 > out
cat >expected <<EOF
0
0
EOF
diff out expected