Skip to content

Commit debcf2a

Browse files
Merge branch 'coursework/sprint-3-practice-tdd' of https://github.com/Yonatanteklemariam/Module-Structuring-and-Testing-Data into coursework/sprint-3-practice-tdd
2 parents 16e1c56 + 49f7123 commit debcf2a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Sprint-3/2-practice-tdd/repeat-str.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const repeatStr = require("./repeat-str");
1111

1212
test("should repeat the string count times", () => {
1313
const str = "hello";
14-
const count = -5;
14+
const count = 3;
1515
const repeatedStr = repeatStr(str, count);
1616
expect(repeatedStr).toEqual("hellohellohello");
1717
});
@@ -42,7 +42,7 @@ test("should repeat the string count of 0", () => {
4242

4343
// Case: Handle negative count:
4444
test(`should throw an error for negative count`, () => {
45-
expect(() => repeatedStr("fella", -2)).toThrowError();
45+
expect(() => repeatStr("fella", -2)).toThrowError();
4646
});
4747
// Given a target string `str` and a negative integer `count`,
4848
// When the repeatStr function is called with these inputs,

0 commit comments

Comments
 (0)