Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Rick Smetsers
z3gi
Commits
25eb76d3
Commit
25eb76d3
authored
Jul 11, 2017
by
Paul Fiterau Brostean
Browse files
many print-outs
parent
8577efcc
Changes
1
Hide whitespace changes
Inline
Side-by-side
z3gi/benchmark.py
View file @
25eb76d3
...
@@ -70,7 +70,8 @@ class Benchmark:
...
@@ -70,7 +70,8 @@ class Benchmark:
learner
.
set_timeout
(
tout
)
learner
.
set_timeout
(
tout
)
# ugly but there you go
# ugly but there you go
rand_length
=
size
+
test_desc
.
rand_length
rand_length
=
size
+
test_desc
.
rand_length
tester
=
test_gen
(
sut
,
rand_length
,
test_desc
.
prop_reset
)
prop_reset
=
1
/
rand_length
tester
=
test_gen
(
sut
,
rand_length
,
prop_reset
)
(
model
,
statistics
)
=
learn_mbt
(
learner
,
tester
,
test_desc
.
max_tests
)
(
model
,
statistics
)
=
learn_mbt
(
learner
,
tester
,
test_desc
.
max_tests
)
if
model
is
None
:
if
model
is
None
:
break
break
...
@@ -118,13 +119,13 @@ b = Benchmark()
...
@@ -118,13 +119,13 @@ b = Benchmark()
# add the sut classes we want to benchmark
# add the sut classes we want to benchmark
#b.add_sut(LoginClass(), SUTType.DFA)
#b.add_sut(LoginClass(), SUTType.DFA)
b
.
add_sut
(
FIFOSetClass
()
,
SUTType
.
Mealy
)
b
.
add_sut
(
FIFOSetClass
())
# create a test description
# create a test description
t_desc
=
TestDesc
(
max_tests
=
10000
,
prop_reset
=
0.1
,
rand_length
=
5
)
t_desc
=
TestDesc
(
max_tests
=
10000
,
prop_reset
=
0.1
,
rand_length
=
5
)
# give an smt timeout value (in ms)
# give an smt timeout value (in ms)
timeout
=
100
000
timeout
=
100
# run the benchmark and collect results
# run the benchmark and collect results
results
=
b
.
run_benchmarks
(
t_desc
,
timeout
)
results
=
b
.
run_benchmarks
(
t_desc
,
timeout
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment