@@ -67,7 +67,7 @@ Note, the counterexamples from this property are not shrunk (see why below).
6767See Note [Debugging generators that don't generate well-typed/kinded terms/types]
6868and the utility properties below when this property fails. -}
6969p_genTypeCorrect :: Bool -> Property
70- p_genTypeCorrect debug = withMaxSuccess 200 $ do
70+ p_genTypeCorrect debug = BaseQC. withNumTests 200 $ do
7171 -- Note, we don't shrink this term here because a precondition of shrinking is that
7272 -- the term we are shrinking is well-typed. If it is not, the counterexample we get
7373 -- from shrinking will be nonsene.
@@ -77,7 +77,7 @@ p_genTypeCorrect debug = withMaxSuccess 200 $ do
7777{-| Test that when we generate a fully applied term we end up
7878with a well-typed term. -}
7979prop_genWellTypedFullyApplied :: Property
80- prop_genWellTypedFullyApplied = withMaxSuccess 50 $
80+ prop_genWellTypedFullyApplied = BaseQC. withNumTests 50 $
8181 forAllDoc " ty, tm" genTypeAndTerm_ shrinkClosedTypedTerm $ \ (ty, tm) ->
8282 -- No shrinking here because if `genFullyApplied` is wrong then the shrinking
8383 -- will be wrong too. See `prop_genTypeCorrect`.
@@ -87,7 +87,7 @@ prop_genWellTypedFullyApplied = withMaxSuccess 50 $
8787-- | Test that shrinking a well-typed term results in a well-typed term
8888prop_shrinkTermSound :: Property
8989-- The test is disabled, because it's exponential and was hanging CI.
90- prop_shrinkTermSound = withMaxSuccess 0 $
90+ prop_shrinkTermSound = BaseQC. withNumTests 0 $
9191 forAllDoc " ty,tm" genTypeAndTerm_ shrinkClosedTypedTerm $ \ (ty, tm) ->
9292 let shrinks = shrinkClosedTypedTerm (ty, tm)
9393 in -- While we generate well-typed terms we still need this check here for
@@ -112,7 +112,7 @@ prop_shrinkTermSound = withMaxSuccess 0 $
112112
113113-- | Test that `findInstantiation` results in a well-typed instantiation.
114114prop_findInstantiation :: Property
115- prop_findInstantiation = withMaxSuccess 1000 $
115+ prop_findInstantiation = BaseQC. withNumTests 1000 $
116116 forAllDoc " ctx" genCtx (const [] ) $ \ ctx0 ->
117117 forAllDoc " ty" (genTypeWithCtx ctx0 $ Type () ) (shrinkType ctx0) $ \ ty0 ->
118118 forAllDoc " target" (genTypeWithCtx ctx0 $ Type () ) (shrinkType ctx0) $ \ target ->
@@ -149,7 +149,7 @@ prop_findInstantiation = withMaxSuccess 1000 $
149149
150150-- | Check what's in the leaves of the generated data
151151prop_stats_leaves :: Property
152- prop_stats_leaves = withMaxSuccess 10 $
152+ prop_stats_leaves = BaseQC. withNumTests 10 $
153153 -- No shrinking here because we are only collecting stats
154154 forAllDoc " _,tm" genTypeAndTerm_ (const [] ) $ \ (_, tm) ->
155155 tabulate " leaves" (map (filter isAlpha . show . prettyReadable) $ leaves tm) $ property True
@@ -168,7 +168,7 @@ prop_stats_leaves = withMaxSuccess 10 $
168168-- | Check the ratio of duplicate shrinks
169169prop_stats_numShrink :: Property
170170-- The test is disabled, because it's exponential and was hanging CI.
171- prop_stats_numShrink = withMaxSuccess 0 $
171+ prop_stats_numShrink = BaseQC. withNumTests 0 $
172172 -- No shrinking here because we are only collecting stats
173173 forAllDoc " ty,tm" genTypeAndTerm_ (const [] ) $ \ (ty, tm) ->
174174 let shrinks = map snd $ shrinkClosedTypedTerm (ty, tm)
@@ -181,7 +181,7 @@ prop_stats_numShrink = withMaxSuccess 0 $
181181
182182-- | Specific test that `inhabitType` returns well-typed things
183183prop_inhabited :: Property
184- prop_inhabited = withMaxSuccess 50 $
184+ prop_inhabited = BaseQC. withNumTests 50 $
185185 -- No shrinking here because if the generator
186186 -- generates nonsense shrinking will be nonsense.
187187 forAllDoc " ty,tm" (genInhab mempty ) (const [] ) $
@@ -201,7 +201,7 @@ prop_inhabited = withMaxSuccess 50 $
201201-- | Check that there are no one-step shrink loops
202202prop_noTermShrinkLoops :: Property
203203-- The test is disabled, because it's exponential and was hanging CI.
204- prop_noTermShrinkLoops = withMaxSuccess 0
204+ prop_noTermShrinkLoops = BaseQC. withNumTests 0
205205 $
206206 -- Note that we need to remove x from the shrinks of x here because
207207 -- a counterexample to this property is otherwise guaranteed to
@@ -226,7 +226,7 @@ noStructuralErrors term =
226226
227227-- | Test that evaluation of well-typed terms doesn't fail with a structural error.
228228prop_noStructuralErrors :: Property
229- prop_noStructuralErrors = withMaxSuccess 99 $
229+ prop_noStructuralErrors = BaseQC. withNumTests 99 $
230230 forAllDoc " ty,tm" genTypeAndTerm_ shrinkClosedTypedTerm $ \ (_, termPir) -> ioProperty $ do
231231 termUPlc <-
232232 fmap UPLC. _progTerm . modifyError (userError . displayException) . toUPlc $
0 commit comments