From 24ab2c33e3d898d487bd17db7836e4f7868e12bc Mon Sep 17 00:00:00 2001 From: samsiegart Date: Tue, 17 Dec 2024 22:39:56 -0800 Subject: [PATCH] fixup! feat(fast-usdc): detect transfer completion in cli --- packages/fast-usdc/src/util/bank.js | 10 ++++------ packages/fast-usdc/test/cli/transfer.test.ts | 2 +- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/packages/fast-usdc/src/util/bank.js b/packages/fast-usdc/src/util/bank.js index f433858c065..24f1ced5265 100644 --- a/packages/fast-usdc/src/util/bank.js +++ b/packages/fast-usdc/src/util/bank.js @@ -1,10 +1,8 @@ -/* global globalThis */ - export const queryUSDCBalance = async ( - address, - api, - denom, - fetch = globalThis.fetch, + /** @type {string} */ address, + /** @type {string} */ api, + /** @type {string} */ denom, + /** @type {typeof globalThis.fetch} */ fetch, ) => { const query = `${api}/cosmos/bank/v1beta1/balances/${address}`; const json = await fetch(query).then(res => res.json()); diff --git a/packages/fast-usdc/test/cli/transfer.test.ts b/packages/fast-usdc/test/cli/transfer.test.ts index 6ae781d74d2..0b23281aed7 100644 --- a/packages/fast-usdc/test/cli/transfer.test.ts +++ b/packages/fast-usdc/test/cli/transfer.test.ts @@ -120,7 +120,7 @@ test('Transfer registers the noble forwarding account if it does not exist', asy { signer: signerMock.signer, address: nobleSignerAddress }, mockEthProvider.provider, ); - + console.log(out.getLogOut()); t.is(vstorageMock.getQueryCounts()[settlementAccountVstoragePath], 1); t.is(fetchMock.getQueryCounts()[nobleFwdAccountQuery], 1); t.snapshot(signerMock.getSigned());