Skip to content

Commit

Permalink
Merge pull request #149 from scrtlabs/indecisive-ci-fix
Browse files Browse the repository at this point in the history
Indecisive ci fix
  • Loading branch information
Cashmaney committed Jun 15, 2023
2 parents f83f47d + 8588a12 commit 8a6e1e5
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions test/ibc.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import {
createIbcChannel,
createIbcConnection,
loopRelayer,
passParameterChangeProposal,
passParameterChangeProposal, sleep,
turnIbcSwitchOff,
turnIbcSwitchOn,
waitForChainToStart,
Expand Down Expand Up @@ -420,9 +420,17 @@ describe("ibcResponses", () => {
}
expect(tx.code).toBe(TxResultCode.Success);

const txs = await secretjs.query.txsQuery(
`tx.hash='${tx.transactionHash}'`,
);
let txs: TxResponse[] = [];
let tries = 4;
while (txs?.length === 0 && tries > 0) {
// since this is immediately after tx broadcast,
// give some time for it to register in the node
await sleep(150);
txs = await secretjs.query.txsQuery(
`tx.hash='${tx.transactionHash}'`,
);
tries--;
}

expect(txs.length).toBe(1);
expect(txs[0].ibcResponses.length).toBe(0);
Expand Down

0 comments on commit 8a6e1e5

Please sign in to comment.