Skip to content

Commit

Permalink
test: refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
pcheremu committed Jan 5, 2024
1 parent e0b9368 commit 9136685
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions packages/integration-tests/tests/api/transactions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1004,9 +1004,7 @@ describe("Transactions", () => {
"Verify /api?module=transaction&action=getstatus response returns elements" +
" getstatus => getstatus&txhash={tx_hash}",
async () => {
const blocks = await request(environment.blockExplorerAPI).get("/transactions");

const txHash = blocks.body.items[0].hash;
txHash = await helper.getStringFromFile(bufferFile + Buffer.txEthTransfer);
const apiRoute = `/api?module=transaction&action=getstatus&txhash=${txHash}`;
await setTimeout(localConfig.extendedPause); //works unstable without timeout

Expand All @@ -1026,9 +1024,7 @@ describe("Transactions", () => {
"Verify /api?module=transaction&action=gettxreceiptstatus response returns elements" +
" gettxreceiptstatus => gettxreceiptstatus&txhash={tx_hash}",
async () => {
const blocks = await request(environment.blockExplorerAPI).get("/transactions");

const txHash = blocks.body.items[0].hash;
txHash = await helper.getStringFromFile(bufferFile + Buffer.txEthTransfer);
const apiRoute = `/api?module=transaction&action=gettxreceiptstatus&txhash=${txHash}`;
await setTimeout(localConfig.extendedPause); //works unstable without timeout

Expand Down

0 comments on commit 9136685

Please sign in to comment.