Skip to content
This repository has been archived by the owner on Jun 26, 2023. It is now read-only.

Commit

Permalink
Increase the number of test cases to run in our property tests and de…
Browse files Browse the repository at this point in the history
…crease the

upper bound of the generated traces length.
  • Loading branch information
dnadales committed May 4, 2021
1 parent 89ce298 commit 2b84c1d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Expand Up @@ -66,9 +66,11 @@ runTests = [
$ forAllTracesShow (implsAreNot Expired) (const "")
, testProperty "Implementations are rejected"
$ expectFailure
$ withMaxSuccess 10000
$ forAllTracesShow (implsAreNot Rejected) (const "")
, testProperty "Implementations get no-quorum"
$ expectFailure
$ withMaxSuccess 10000
$ forAllTracesShow (implsAreNot WithNoQuorum) (const "")
-- We do not test that implementations are approved since that is
-- implicitly tested when we test that updates are activated.
Expand All @@ -81,6 +83,7 @@ runTests = [
$ forAllTracesShow updatesAreNotActivated (const "")
, testProperty "Implementations are queued"
$ expectFailure
$ withMaxSuccess 10000
$ forAllTracesShow updatesAreNotQueued (const "")
, testProperty "Updates are discarded due to being expired"
$ expectFailure
Expand All @@ -98,7 +101,7 @@ runTests = [
-- Update system safety properties
---------------------------------------------------------------------
, testProperty "Changes in the state of update proposals are valid."
$ withMaxSuccess 2000
$ withMaxSuccess 100000
$ forAllTracesShow
StateChangeValidity.prop_updateEventTransitionsAreValid
showActionsAndStateOfUpdateSpec
Expand Down
Expand Up @@ -491,7 +491,7 @@ genActions participants specs = do
-- number of slots per epoch, number of participants, etc. Also we can tune
-- this based on the coverage metrics: if shorter traces cover all the
-- relevant cases, then there is no need to use such high number.
traceLength <- choose (1, 10000)
traceLength <- choose (1, 1000)
let nrSpecs = length specs
sipVotersBehaviors <- vectorOf nrSpecs genVotersBehavior
implVotersBehavior <- vectorOf nrSpecs genVotersBehavior
Expand Down

0 comments on commit 2b84c1d

Please sign in to comment.