first Jest test 💫
continuous-integration/drone/push Build is passing Details

Tests
Lucas Delanier 2 years ago
parent ed46cec5a7
commit 1ce81289c8

@ -0,0 +1,14 @@
import {describe, expect, test} from '@jest/globals';
import {formatTime} from "../../model/formatTime";
describe('return formated time', () => {
test('125to 2h 05m', () => {
expect(formatTime(125)).toBe("2h 05m");
});
test('45to 0h 45m', () => {
expect(formatTime(45)).toBe("0h 45m");
});
test('203to 3h 23m', () => {
expect(formatTime(203)).toBe("3h 23m");
});
});

2213
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -61,6 +61,8 @@
},
"devDependencies": {
"@babel/core": "^7.12.9",
"@jest/globals": "^29.5.0",
"@types/jest": "^29.5.0",
"@types/react": "~18.0.24",
"@types/react-native": "~0.70.6",
"jest": "^26.6.3",

Loading…
Cancel
Save