Skip to content

Commit

Permalink
use on-disk database in integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
KtorZ committed Jan 16, 2020
1 parent d492c8f commit 4ed4d42
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions lib/jormungandr/test/integration/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ import System.Environment
( setEnv )
import System.FilePath
( (</>) )
import System.IO.Temp
( withSystemTempDirectory )
import Test.Hspec
( Spec, SpecWith, after, describe, hspec, parallel )
import Test.Hspec.Extra
Expand Down Expand Up @@ -171,8 +173,15 @@ specWithServer tr = aroundAll withContext . after tearDown
withServer setup =
withConfig $ \jmCfg ->
withMetadataRegistry $
serveWallet @'Testnet tracers (SyncTolerance 10) Nothing "127.0.0.1"
ListenOnRandomPort (Launch jmCfg) setup
withSystemTempDirectory "cardano-wallet-databases" $ \db ->
serveWallet @'Testnet
tracers
(SyncTolerance 10)
(Just db)
"127.0.0.1"
ListenOnRandomPort
(Launch jmCfg)
setup

tracers = setupTracers (tracerSeverities (Just Info)) tr

Expand Down

0 comments on commit 4ed4d42

Please sign in to comment.