Skip to content

Commit cf43501

Browse files
committed
Add three more tests to cover different situations
1 parent 922e296 commit cf43501

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

Sprint-3/1-implement-and-rewrite-tests/rewrite-tests-with-jest/2-is-proper-fraction.test.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,14 @@ test("returns true for a negative proper fraction( absolute value of the numerat
1818
test("returns false when numerator equals denominator", () => {
1919
expect(isProperFraction(9, 9)).toEqual(false);
2020
});
21+
22+
test("return false when numerator equals denominator when both are negative",()=>{
23+
expect(isProperFraction(-4,-4)).toEqual(false);
24+
});
25+
26+
test("returns false for a negative proper fraction( absolute value of the denominator is less than the numerator)", () => {
27+
expect(isProperFraction(-7, 4)).toEqual(false);
28+
});
29+
test("returns false when denominator is zero", () => {
30+
expect(isProperFraction(3, 0)).toEqual(false);
31+
});

0 commit comments

Comments
 (0)