mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 23:27:43 +00:00
LibJS: Use Number instead of parseInt in TypedArray forEach BigInt tests
The Number constructor previously didn't support converting BigInts to regular numbers, so I used parseInt as a workaround. Since it now supports this, this workaround is no longer needed.
This commit is contained in:
parent
8244d7916e
commit
651becbfb1
1 changed files with 1 additions and 1 deletions
|
@ -95,7 +95,7 @@ describe("normal behaviour", () => {
|
|||
const typedArray = new T([1n, 2n, 3n]);
|
||||
typedArray.forEach((value, index) => {
|
||||
expect(value).toBe(typedArray[index]);
|
||||
expect(index).toBe(parseInt(typedArray[index] - 1n));
|
||||
expect(index).toBe(Number(typedArray[index] - 1n));
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue