Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion libs/cardano-ledger-test/cardano-ledger-test.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,9 @@ test-suite cardano-ledger-test

build-depends:
base,
cardano-ledger-core:testlib,
cardano-ledger-test,
tasty,
tasty-hspec,

benchmark bench
type: exitcode-stdio-1.0
Expand Down
11 changes: 6 additions & 5 deletions libs/cardano-ledger-test/test/Tests.hs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ module Main where

import System.Environment (lookupEnv)
import System.IO (hSetEncoding, stdout, utf8)
import Test.Cardano.Ledger.Common (hspec)
import qualified Test.Cardano.Ledger.Constrained.Conway.LedgerTypes.Tests as LedgerTypes
import qualified Test.Cardano.Ledger.Constrained.Conway.MiniTrace as MiniTrace
import qualified Test.Cardano.Ledger.Examples.AlonzoAPI as AlonzoAPI (tests)
Expand All @@ -23,17 +22,19 @@ import qualified Test.Cardano.Ledger.NoThunks as NoThunks
import qualified Test.Cardano.Ledger.STS as ConstraintSTS
import Test.Cardano.Ledger.Tickf (calcPoolDistOldEqualsNew)
import Test.Tasty (TestTree, defaultMain, testGroup)
import Test.Tasty.Hspec (testSpec)

main :: IO ()
main = do
hSetEncoding stdout utf8
nightly <- lookupEnv "NIGHTLY"
hspec MiniTrace.spec
minitrace <- testSpec "MiniTrace" MiniTrace.spec
case nightly of
Nothing -> defaultMain $ testGroup "cardano-core" defaultTests
Nothing -> do
defaultMain $ testGroup "cardano-core" $ minitrace : defaultTests
Just _ -> do
hspec LedgerTypes.spec
defaultMain $ testGroup "cardano-core - nightly" nightlyTests
ledgerTypesSpec <- testSpec "LedgerTypes" LedgerTypes.spec
defaultMain $ testGroup "cardano-core - nightly" $ ledgerTypesSpec : nightlyTests

defaultTests :: [TestTree]
defaultTests =
Expand Down
Loading