Skip to content

Commit 3fafedf

Browse files
committed
Add test cases for angle types and update Sprint-1 readme
1 parent 2479c4f commit 3fafedf

File tree

3 files changed

+3406
-15
lines changed

3 files changed

+3406
-15
lines changed

Sprint-1/readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ This README will guide you through the different sections for this week.
1212

1313
## 1 Exercises
1414

15-
In this section, you'll have a short program and task. Some of the syntax may be unfamiliar - in this case, you'll need to look things up in documentation.
15+
In this section, you'll have a short program and task. Some of the syntax may be unfamiliar - in this case, you'll need to look things up in documentation.
1616

1717
https://developer.mozilla.org/en-US/docs/Web/JavaScript
1818

@@ -28,7 +28,7 @@ You must use documentation to make sense of anything unfamiliar - learning how t
2828

2929
You can also use `console.log` to check the value of different variables in the code.
3030

31-
https://developer.mozilla.org/en-US/docs/Web/JavaScript
31+
https://developer.mozilla.org/en-US/docs/Web/JavaScript
3232

3333
## 4 Explore - Stretch 💪
3434

Sprint-3/2-mandatory-rewrite/1-get-angle-type.test.js

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,22 @@ test("should identify right angle (90°)", () => {
66

77
// REPLACE the comments with the tests
88
// make your test descriptions as clear and readable as possible
9+
test("should identify acute angle (< 90°)", () => {
10+
expect(getAngleType(45)).toEqual("Acute angle");
11+
});
12+
// Case 2: identify Acute Angles, When the angle is less than 90 degrees, than the function should return "Acute angle".
913

10-
// Case 2: Identify Acute Angles:
11-
// When the angle is less than 90 degrees,
12-
// Then the function should return "Acute angle"
13-
14-
// Case 3: Identify Obtuse Angles:
15-
// When the angle is greater than 90 degrees and less than 180 degrees,
16-
// Then the function should return "Obtuse angle"
14+
test("should identify obtuse angle (> 90° and < 180°)", () => {
15+
expect(getAngleType(120)).toEqual("Obtuse angle");
16+
});
17+
// Case 3: identify Obtuse Angles, When the angle is greater than 90 degrees and less than 180 degrees, than the function should return "Obtuse Angle".
1718

18-
// Case 4: Identify Straight Angles:
19-
// When the angle is exactly 180 degrees,
20-
// Then the function should return "Straight angle"
19+
test("should identify straight angle (180°)", () => {
20+
expect(getAngleType(180)).toEqual("Straight angle");
21+
});
22+
// Case 4: identify Straight Angles, When the angle is exactly 180 degrees, than the function should return "Straight angle".
2123

22-
// Case 5: Identify Reflex Angles:
23-
// When the angle is greater than 180 degrees and less than 360 degrees,
24-
// Then the function should return "Reflex angle"
24+
test("should identify reflex angle (> 180° and < 360°)", () => {
25+
expect(getAngleType(270)).toEqual("Reflex angle");
26+
});
27+
// Case 5: identify Reflex Angles, When the angle is greater than 180 degrees and less than 360 degrees, the function should return "Reflex Angle".

0 commit comments

Comments
 (0)