Skip to content

Commit

Permalink
Restyled by fourmolu (#2203)
Browse files Browse the repository at this point in the history
Co-authored-by: Restyled.io <[email protected]>
  • Loading branch information
github-actions[bot] and restyled-commits authored Nov 5, 2024
1 parent d5e6ae5 commit a641252
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/unit/TestContext.hs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import Swarm.Util (showT)
import Test.QuickCheck.Instances.Text ()
import Test.Tasty (TestTree, testGroup)
import Test.Tasty.HUnit (Assertion, assertBool, assertEqual, testCase)
import Test.Tasty.QuickCheck (testProperty, Gen, generate, withMaxSuccess, Arbitrary(..))
import Test.Tasty.QuickCheck (Arbitrary (..), Gen, generate, testProperty, withMaxSuccess)

testContext :: TestTree
testContext =
Expand Down Expand Up @@ -47,11 +47,11 @@ testContext =
"no paired hash collisions"
(withMaxSuccess 10000 (hashConsistent @Int))
, testCase
"no hash collisions in a large pool" $
do
"no hash collisions in a large pool"
$ do
ctxs <- generate (replicateM 100000 (arbitrary :: Gen (Ctx Int)))
let m = M.fromListWith (++) (map (\ctx -> (ctxHash ctx, [unCtx ctx])) ctxs)
assertBool "foo" $ all ((==1) . length . nub) m
assertBool "foo" $ all ((== 1) . length . nub) m
]
where
ctx1 = singleton "x" 3
Expand Down

0 comments on commit a641252

Please sign in to comment.