Skip to content

Commit

Permalink
Make PBT computes_a_fixpoint adjustable
Browse files Browse the repository at this point in the history
  • Loading branch information
facundominguez committed Dec 15, 2023
1 parent 04e4300 commit 2bd985a
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/tasty/InterpretTests.hs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Language.Fixpoint.Types.Refinements (Expr (..))
import qualified SimplifyInterpreter
import Test.Tasty
( TestTree,
localOption,
adjustOption,
testGroup,
)
import Test.Tasty.QuickCheck
Expand All @@ -24,7 +24,10 @@ tests =
[ testProperty "computes a fixpoint" (prop_fixpoint SimplifyInterpreter.interpret')
]
where
withOptions tests' = localOption (QuickCheckMaxSize 4) (localOption (QuickCheckTests 500) tests')
withOptions tests' =
adjustOption (\(QuickCheckMaxSize n) -> QuickCheckMaxSize (div n 4)) $
adjustOption (\(QuickCheckTests n) -> QuickCheckTests (n * 20)) $

Check warning on line 29 in tests/tasty/InterpretTests.hs

View workflow job for this annotation

GitHub Actions / hlint-3.4

Suggestion in tests in module InterpretTests: Redundant $ ▫︎ Found: "adjustOption (\\ (QuickCheckTests n) -> QuickCheckTests (n * 20))\n $ tests'" ▫︎ Perhaps: "adjustOption\n (\\ (QuickCheckTests n) -> QuickCheckTests (n * 20)) tests'"

Check warning on line 29 in tests/tasty/InterpretTests.hs

View workflow job for this annotation

GitHub Actions / hlint-3.4

Suggestion in tests in module InterpretTests: Redundant $ ▫︎ Found: "adjustOption (\\ (QuickCheckTests n) -> QuickCheckTests (n * 20))\n $ tests'" ▫︎ Perhaps: "adjustOption\n (\\ (QuickCheckTests n) -> QuickCheckTests (n * 20)) tests'"
tests'

prop_fixpoint :: (Expr -> Expr) -> Expr -> Property
prop_fixpoint f e = f e === f (f e)

0 comments on commit 2bd985a

Please sign in to comment.