Skip to content
Permalink
Browse files

remove logical branching to make integration test fail

  • Loading branch information...
KtorZ committed May 15, 2019
1 parent aecc07f commit 9a7974ed5df9ac5e21d948ff89f77a331d354fe8
Showing with 2 additions and 6 deletions.
  1. +2 −6 lib/http-bridge/test/integration/Test/Integration/Scenario/Wallets.hs
@@ -1207,20 +1207,16 @@ spec = do
let payload = updatePassPayload "Secure passphrase" "Secure passphrase2"
let delEndp = "v2/wallets" </> (getFromResponse walletId r)
_ <- request @ApiWallet ctx ("DELETE", delEndp) Default Empty

let updEndp = delEndp </> ("passphrase" :: Text)
rup <- request @ApiWallet ctx ("PUT", updEndp) Default payload
expectResponseCode @IO HTTP.status403 rup
expectResponseCode @IO HTTP.status404 rup

describe "WALLETS_UPDATE_PASS_04 - non-existing wallets" $ do
forM_ falseWalletIds $ \(title, walId) -> it title $ \ctx -> do
let payload = updatePassPayload "Secure passphrase" "Secure passphrase2"
let endpoint = "v2/wallets" </> T.pack walId </> ("passphrase" :: Text)
rup <- request @ApiWallet ctx ("PUT", endpoint) Default payload
if (title == "40 chars hex") then
expectResponseCode @IO HTTP.status403 rup
else
expectResponseCode @IO HTTP.status404 rup
expectResponseCode @IO HTTP.status404 rup

it "WALLETS_UPDATE_PASS_04 - 'almost' valid walletId" $ \ctx -> do
r <- request @ApiWallet ctx ("POST", "v2/wallets") Default simplePayload

0 comments on commit 9a7974e

Please sign in to comment.
You can’t perform that action at this time.