Skip to content

Commit

Permalink
Initialize the underlying library before the test suite begins
Browse files Browse the repository at this point in the history
  • Loading branch information
exarkun committed Sep 14, 2023
1 parent 90a980f commit 5b31be3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions haskell/test/FECTest.hs
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,10 @@ prop_primary_copies (Params _ tot) primary = property $ do
secondary = FEC.encode fec [BL.toStrict primary]

main :: IO ()
main = hspec $
parallel $ do
main = do
-- Be sure to do the required zfec initialization first.
FEC.initialize
hspec . parallel $ do
describe "encode" $ do
-- This test originally caught a bug in multi-threaded
-- initialization of the C library. Since it is in the
Expand Down

0 comments on commit 5b31be3

Please sign in to comment.