Issues (19)

test/utils/helpers/numbers.test.js (1 issue)

Labels
Severity
1
import { roundTen } from '../../../src/utils/helpers/numbers';
2
3
describe('numbers', () => {
4
  describe('roundTen', () => {
5
    it('rounds provided number to the next multiple of ten', () => {
6
      const expectationsPairs = [
7
        [ 10, 10 ],
8
        [ 12, 20 ],
9
        [ 158, 160 ],
10
        [ 5, 10 ],
11
        [ -42, -40 ],
12
      ];
13
14
      expect.assertions(expectationsPairs.length);
0 ignored issues
show
The variable expect seems to be never declared. If this is a global, consider adding a /** global: expect */ comment.

This checks looks for references to variables that have not been declared. This is most likey a typographical error or a variable has been renamed.

To learn more about declaring variables in Javascript, see the MDN.

Loading history...
15
      expectationsPairs.forEach(([ number, expected ]) => {
16
        expect(roundTen(number)).toEqual(expected);
17
      });
18
    });
19
  });
20
});
21