Skip to content

Commit 1f444ba

Browse files
committed
fix viem test
1 parent 9feaeed commit 1f444ba

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

packages/thirdweb/src/adapters/viem.test.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import { type Account as ViemAccount, zeroAddress } from "viem";
1+
import type { Account as ViemAccount } from "viem";
22
import { privateKeyToAccount as viemPrivateKeyToAccount } from "viem/accounts";
33
import { beforeAll, describe, expect, test } from "vitest";
44
import { USDT_ABI } from "~test/abis/usdt.js";
55
import {
66
USDT_CONTRACT_ADDRESS,
77
USDT_CONTRACT_WITH_ABI,
88
} from "~test/test-contracts.js";
9-
import { ANVIL_PKEY_A } from "~test/test-wallets.js";
9+
import { ANVIL_PKEY_A, TEST_ACCOUNT_B } from "~test/test-wallets.js";
1010
import { typedData } from "~test/typed-data.js";
1111

1212
import { ANVIL_CHAIN, FORKED_ETHEREUM_CHAIN } from "../../test/src/chains.js";
@@ -87,6 +87,7 @@ describe("walletClient.toViem", () => {
8787
if (!walletClient.account) {
8888
throw new Error("Account not found");
8989
}
90+
9091
const txHash = await walletClient.sendTransaction({
9192
account: walletClient.account,
9293
chain: {
@@ -101,8 +102,8 @@ describe("walletClient.toViem", () => {
101102
decimals: ANVIL_CHAIN.nativeCurrency?.decimals || 18,
102103
},
103104
},
104-
to: zeroAddress,
105-
value: 0n,
105+
to: TEST_ACCOUNT_B.address,
106+
value: 10n,
106107
});
107108
expect(txHash).toBeDefined();
108109
expect(txHash.slice(0, 2)).toBe("0x");

0 commit comments

Comments
 (0)