diff --git a/package-lock.json b/package-lock.json index 79127efc..f6abf20a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,7 +15,7 @@ "eslint": "^5.16.0", "eslint-plugin-jest": "^22.4.1", "eslint-plugin-node": "^8.0.1", - "jest": "^24.5.0" + "jest": "^24.9.0" } }, "node_modules/@babel/code-frame": { @@ -3567,6 +3567,7 @@ "resolved": "https://registry.npmjs.org/jest/-/jest-24.9.0.tgz", "integrity": "sha512-YvkBL1Zm7d2B1+h5fHEOdyjCG+sGMz4f8D86/0HiqJ6MB4MnDc8FgP5vdWsGnemOQro7lnYo8UakZ3+5A0jxGw==", "dev": true, + "license": "MIT", "dependencies": { "import-local": "^2.0.0", "jest-cli": "^24.9.0" diff --git a/package.json b/package.json index f782ac5a..077b4aee 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ "eslint": "^5.16.0", "eslint-plugin-jest": "^22.4.1", "eslint-plugin-node": "^8.0.1", - "jest": "^24.5.0" + "jest": "^24.9.0" }, "mateAcademy": { "projectType": "javascript" diff --git a/src/splitInteger.test.js b/src/splitInteger.test.js index a610317d..9f708f43 100644 --- a/src/splitInteger.test.js +++ b/src/splitInteger.test.js @@ -1,21 +1,21 @@ -'use strict'; +"use strict"; -const splitInteger = require('./splitInteger'); +const splitInteger = require("./splitInteger"); test(`should split a number into equal parts if a value is divisible by a numberOfParts`, () => { - + expect(splitInteger(6, 2)).toEqual([3, 3]); }); test(`should return a part equals to a value when splitting into 1 part`, () => { - + expect(splitInteger(8, 1)).toEqual([8]); }); -test('should sort parts ascending if they are not equal', () => { - +test("should sort parts ascending if they are not equal", () => { + expect(splitInteger(32, 6)).toEqual([5, 5, 5, 5, 6, 6]); }); -test('should add zeros if value < numberOfParts', () => { - +test("should add zeros if value < numberOfParts", () => { + expect(splitInteger(3, 5)).toEqual([0, 0, 1, 1, 1]); });