Skip to content

Commit

Permalink
improve test
Browse files Browse the repository at this point in the history
  • Loading branch information
jscriptcoder committed Jul 5, 2023
1 parent 30e5a80 commit 0ab69ca
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/bridge-ui/src/utils/toBigNumber.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,8 @@ describe('toBigNumber', () => {
expect(toBigNumber(2e+21).toString()).toEqual('2000000000000000000000');
expect(toBigNumber(3e21).toString()).toEqual('3000000000000000000000');
expect(toBigNumber(1000).toString()).toEqual('1000');

// Number.MAX_SAFE_INTEGER = 9007199254740991. Maximum safe integer (2^53 – 1)
expect(toBigNumber(BigInt(Number.MAX_SAFE_INTEGER) * 3n).toString()).toEqual('27021597764222973');
});
});

0 comments on commit 0ab69ca

Please sign in to comment.