Skip to content

Commit

Permalink
Merge #1785
Browse files Browse the repository at this point in the history
1785: integration tests: Shorten cardano-node socket path r=Anviking a=rvl

### Issue Number

ADP-302 / #1750

### Overview

The socket path needs to be short enough to work in the default temp directory on macOS.


Co-authored-by: Rodney Lorrimar <[email protected]>
  • Loading branch information
iohk-bors[bot] and rvl authored Jun 23, 2020
2 parents 7e49dad + 4a032fd commit 0fc30a0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/byron/src/Cardano/Wallet/Byron/Launch.hs
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ withConfig tdir minSeverity action =
let nodeSocketFile =
if os == "mingw32"
then "\\\\.\\pipe\\" ++ takeFileName dir
else dir </> "node.socket"
else dir </> "socket"

-- we need to specify genesis file location every run in tmp
Yaml.decodeFileThrow (source </> "node.config")
Expand Down
4 changes: 2 additions & 2 deletions lib/shelley/src/Cardano/Wallet/Shelley/Launch.hs
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ withBFTNode tr baseDir (NodeParams severity systemStart (port, peers)) action =
source :: FilePath
source = $(getTestData) </> "cardano-node-shelley"

name = "bft-node"
name = "bft"
dir = baseDir </> name

singleNodeParams :: Severity -> IO NodeParams
Expand Down Expand Up @@ -470,7 +470,7 @@ withStakePool tr baseDir idx params action =
action
where
dir = baseDir </> name
name = "stake-pool-" ++ show idx
name = "pool-" ++ show idx

withCardanoNodeProcess
:: Tracer IO ClusterLog
Expand Down
2 changes: 1 addition & 1 deletion lib/shelley/test/integration/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ specWithServer (tr, tracers) = aroundAll withContext . after tearDown
withServer onStart = bracketTracer' tr "withServer" $ do
minSev <- nodeMinSeverityFromEnv
let tr' = contramap MsgCluster tr
withSystemTempDir tr' "integration" $ \dir ->
withSystemTempDir tr' "test" $ \dir ->
withCluster tr' minSev 3 dir $ \socketPath block0 (gp, vData) ->
withTempDir tr' dir "wallets" $ \db ->
serveWallet @(IO Shelley)
Expand Down

0 comments on commit 0fc30a0

Please sign in to comment.