Skip to content

Commit

Permalink
fix(tests): update test
Browse files Browse the repository at this point in the history
  • Loading branch information
dhruvkelawala committed Jun 15, 2022
1 parent e22c346 commit c71f482
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions __tests__/utils/utils.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ describe('estimatedFeeToMaxFee()', () => {
});
});

describe('Deterministic Address calculation', () => {
describe('calculateContractAddressFromHash()', () => {
// This test just show how to use calculateContractAddressFromHash for new devs

test.only('calculate hash', () => {
test('calculated contract address should match the snapshot', () => {
const ethAddress = '0x049d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7';

const daiAddress = '0x03e85bfbb8e2a42b7bead9e88e9a1b19dbccf661471061807292120462396ec9';
Expand All @@ -109,6 +109,8 @@ describe('Deterministic Address calculation', () => {
factoryAddress
);

expect(res).not.toBeNull();
expect(res).toMatchInlineSnapshot(
`"0x36dc8dcb3440596472ddde11facacc45d0cd250df764ae7c3d1a360c853c324"`
);
});
});

0 comments on commit c71f482

Please sign in to comment.