Skip to content

Commit 051fef8

Browse files
committed
added "goodbye" to repeat-str.test.js
1 parent 1325473 commit 051fef8

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

‎practice-tdd/repeat-str.test.js‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,3 +50,10 @@ test("should throw new error 'count could not be negative' when number of count
5050
const count = -2; () =>
5151
expect(repeatStr).toThrow("count could not be negative");
5252
});
53+
54+
test("should repeat the string count times", () => {
55+
const str = "goodbye";
56+
const count = 5;
57+
const repeatedStr = repeatStr(str, count);
58+
expect(repeatedStr).toEqual("goodbyegoodbyegoodbyegoodbyegoodbye");
59+
});

0 commit comments

Comments
 (0)