Skip to content

Commit

Permalink
chore: rollback changes
Browse files Browse the repository at this point in the history
  • Loading branch information
semeano committed Jan 8, 2025
1 parent d95b944 commit 1b21cde
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
12 changes: 12 additions & 0 deletions libs/ledger-live-common/src/families/aptos/api/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,22 +36,34 @@ describe("Aptos API", () => {
const api = new AptosAPI("aptos");

expect(api.broadcast).toBeDefined();
expect(typeof api.broadcast).toBe("function");
expect(api.estimateGasPrice).toBeDefined();
expect(typeof api.estimateGasPrice).toBe("function");
expect(api.generateTransaction).toBeDefined();
expect(typeof api.generateTransaction).toBe("function");
expect(api.getAccount).toBeDefined();
expect(typeof api.getAccount).toBe("function");
expect(api.getAccountInfo).toBeDefined();
expect(typeof api.getAccountInfo).toBe("function");
expect(api.simulateTransaction).toBeDefined();
expect(typeof api.simulateTransaction).toBe("function");
});

it("builds the client properly for testnet", () => {
const api = new AptosAPI("aptos_testnet");

expect(api.broadcast).toBeDefined();
expect(typeof api.broadcast).toBe("function");
expect(api.estimateGasPrice).toBeDefined();
expect(typeof api.estimateGasPrice).toBe("function");
expect(api.generateTransaction).toBeDefined();
expect(typeof api.generateTransaction).toBe("function");
expect(api.getAccount).toBeDefined();
expect(typeof api.getAccount).toBe("function");
expect(api.getAccountInfo).toBeDefined();
expect(typeof api.getAccountInfo).toBe("function");
expect(api.simulateTransaction).toBeDefined();
expect(typeof api.simulateTransaction).toBe("function");
});

describe("getAccount", () => {
Expand Down
10 changes: 10 additions & 0 deletions libs/ledger-live-common/src/families/aptos/bridge/js.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,26 @@ describe("Aptos bridge interface ", () => {
describe("accountBridge ", () => {
it("should contain all methods", () => {
expect(bridge.accountBridge.estimateMaxSpendable).toBeDefined();
expect(typeof bridge.accountBridge.estimateMaxSpendable).toBe("function");
expect(bridge.accountBridge.createTransaction).toBeDefined();
expect(typeof bridge.accountBridge.createTransaction).toBe("function");
expect(bridge.accountBridge.updateTransaction).toBeDefined();
expect(typeof bridge.accountBridge.updateTransaction).toBe("function");
expect(bridge.accountBridge.getTransactionStatus).toBeDefined();
expect(typeof bridge.accountBridge.getTransactionStatus).toBe("function");
expect(bridge.accountBridge.prepareTransaction).toBeDefined();
expect(typeof bridge.accountBridge.prepareTransaction).toBe("function");
expect(bridge.accountBridge.sync).toBeDefined();
expect(typeof bridge.accountBridge.sync).toBe("function");
expect(bridge.accountBridge.receive).toBeDefined();
expect(typeof bridge.accountBridge.receive).toBe("function");
expect(bridge.accountBridge.signOperation).toBeDefined();
expect(typeof bridge.accountBridge.signOperation).toBe("function");
expect(bridge.accountBridge.broadcast).toBeDefined();
expect(typeof bridge.accountBridge.broadcast).toBe("function");
});
});

describe("updateTransaction", () => {
it("should update the transaction with the given patch", () => {
const initialTransaction = {
Expand Down

0 comments on commit 1b21cde

Please sign in to comment.