Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kev1n-peters committed Jan 6, 2025
1 parent 5a5e612 commit 12dbec0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
8 changes: 4 additions & 4 deletions platforms/aptos/__tests__/integration/tokenBridge.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ describe("TokenBridge Tests", () => {
expect(attestTx!.chain).toEqual(chain);

const { transaction } = attestTx!;
expect(transaction.arguments).toHaveLength(0);
expect(transaction.functionArguments).toHaveLength(0);
});

test("Submit Attestation", async () => {
Expand Down Expand Up @@ -223,7 +223,7 @@ describe("TokenBridge Tests", () => {
expect(xferTx!.chain).toEqual(chain);

const { transaction } = xferTx!;
expect(transaction.arguments).toHaveLength(5);
expect(transaction.functionArguments).toHaveLength(5);
// ...
});

Expand All @@ -242,8 +242,8 @@ describe("TokenBridge Tests", () => {
expect(xferTx!.chain).toEqual(chain);

const { transaction } = xferTx!;
expect(transaction.type_arguments).toHaveLength(1);
expect(transaction.arguments).toHaveLength(5);
expect(transaction.typeArguments).toHaveLength(1);
expect(transaction.functionArguments).toHaveLength(5);
});
});
});
Expand Down
8 changes: 6 additions & 2 deletions platforms/aptos/__tests__/unit/platform.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { AptosChains, AptosPlatform } from "./../../src/index.js";

import "@wormhole-foundation/sdk-aptos-core";
import "@wormhole-foundation/sdk-aptos-tokenbridge";
import { AptosClient } from "aptos";
import { Aptos, AptosConfig, Network as AptosNetwork } from "@aptos-labs/ts-sdk";

const network = DEFAULT_NETWORK;

Expand All @@ -22,7 +22,11 @@ describe("Aptos Platform Tests", () => {
[APTOS_CHAINS[0]!]: configs[APTOS_CHAINS[0]!],
});

const client = new AptosClient(configs[APTOS_CHAINS[0]!]!.rpc);
const config = new AptosConfig({
fullnode: configs[APTOS_CHAINS[0]!]!.rpc,
network: AptosNetwork.MAINNET,
});
const client = new Aptos(config);
const tb = await p.getProtocol("TokenBridge", client);
expect(tb).toBeTruthy();
});
Expand Down

0 comments on commit 12dbec0

Please sign in to comment.