Skip to content

Commit

Permalink
Disable LMDB tests in MINGW32
Browse files Browse the repository at this point in the history
  • Loading branch information
jasagredo committed Sep 21, 2022
1 parent 9d1eae5 commit bc8b949
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
module Test.Ouroboros.Storage.LedgerDB (tests) where

import System.Info (os)

import Test.Tasty

import qualified Test.Ouroboros.Storage.LedgerDB.DbChangelog as DbChangelog
Expand All @@ -9,10 +11,9 @@ import qualified Test.Ouroboros.Storage.LedgerDB.InMemory as InMemory
import qualified Test.Ouroboros.Storage.LedgerDB.OnDisk as OnDisk

tests :: TestTree
tests = testGroup "LedgerDB" [
HD.tests
, InMemory.tests
, OnDisk.tests
, DiskPolicy.tests
, DbChangelog.tests
]
tests = testGroup "LedgerDB" ([ HD.tests | os /= "mingw32" ] <> -- FIXME: Should re-enable at some point, see #4022
[ InMemory.tests
, OnDisk.tests
, DiskPolicy.tests
, DbChangelog.tests
])
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ import Data.Word
import GHC.Generics (Generic)
import qualified System.Directory as Dir
import qualified System.IO.Temp as Temp
import System.Info (os)
import System.Random (getStdRandom, randomR)

import Test.QuickCheck (Gen)
Expand Down Expand Up @@ -102,11 +103,14 @@ import Test.Ouroboros.Storage.LedgerDB.OrphanArbitrary ()

tests :: TestTree
tests = askOption $ \showTrace -> testGroup "OnDisk"
[ TTT.testPropertyTraceable' "LedgerSimple-InMem" $
prop_sequential 100000 (inMemDbEnv showTrace) uniform
, TTT.testPropertyTraceable' "LedgerSimple-LMDB" $
prop_sequential 2000 (lmdbDbEnv showTrace testLMDBLimits) lmdbCustom
]
([ TTT.testPropertyTraceable' "LedgerSimple-InMem" $
prop_sequential 100000 (inMemDbEnv showTrace) uniform
] <>
[ TTT.testPropertyTraceable' "LedgerSimple-LMDB" $
prop_sequential 2000 (lmdbDbEnv showTrace testLMDBLimits) lmdbCustom
| os /= "mingw32" -- FIXME: Should re-enable at some point, see #4022
]
)
where
uniform = CmdDistribution
{ freqCurrent = 1
Expand Down

0 comments on commit bc8b949

Please sign in to comment.