engineeringNotation sometimes has 10 decimal places
We don't truncate decimals on scaledMantissa
, which sometimes leads to stupid JS floating point errors.
example failing spec:
it('correctly truncates floats', () => {
expect(numberUtils.engineeringNotation(0.0000007)).toBe('700n');
});
// Expected: "700n"
// Received: "699.9999999999999n"