Skip to content

Commit

Permalink
Modified checks for deleted redemption requests
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaszslabon committed Nov 8, 2023
1 parent 198cbed commit c0e9c6a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 22 deletions.
22 changes: 8 additions & 14 deletions system-tests/test/deposit-redemption.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -422,14 +422,11 @@ describe("System Test - Deposit and redemption", () => {
})

it("should close the redemption request on the bridge", async () => {
await expect(
maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey.compressed,
redemptionRequest.redeemerOutputScript
)
).to.be.rejectedWith(
"Provided redeemer output script and wallet public key do not identify a redemption request"
const request = await maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey.compressed,
redemptionRequest.redeemerOutputScript
)
expect(request.requestedAt).to.be.equal(0)
})

it("should decrease Bridge's balance in the bank", async () => {
Expand Down Expand Up @@ -724,14 +721,11 @@ describe("System Test - Deposit and redemption", () => {
})

it("should close the redemption request on the bridge", async () => {
await expect(
maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey.compressed,
redemptionRequest.redeemerOutputScript
)
).to.be.rejectedWith(
"Provided redeemer output script and wallet public key do not identify a redemption request"
const request = await maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey.compressed,
redemptionRequest.redeemerOutputScript
)
expect(request.requestedAt).to.be.equal(0)
})

it("should decrease Bridge's balance in the bank", async () => {
Expand Down
12 changes: 4 additions & 8 deletions system-tests/test/minting-unminting.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -484,15 +484,11 @@ describe("System Test - Minting and unminting", () => {
})

it("should close the redemption request on the bridge", async () => {
await expect(
maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey
.compressed,
redemptionRequest.redeemerOutputScript
)
).to.be.rejectedWith(
"Provided redeemer output script and wallet public key do not identify a redemption request"
const request = await maintainerBridgeHandle.pendingRedemptions(
systemTestsContext.walletBitcoinKeyPair.publicKey.compressed,
redemptionRequest.redeemerOutputScript
)
expect(request.requestedAt).to.be.equal(0)
})

it("should decrease Bridge's balance in the bank", async () => {
Expand Down

0 comments on commit c0e9c6a

Please sign in to comment.