Skip to content

Commit b15db6b

Browse files
committed
Fixxed errors in my toThrow
1 parent f1b93ea commit b15db6b

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ test("should repeat the string count 0 times", () => {
4444
test("should throw an error 'negative counts are not valid'", () => {
4545
const str = "hello";
4646
const count = -3;
47-
expect(() => repeatedStr(str, count)).toThrow;
48-
new Error("negative counts are not valid");
47+
expect(() => repeatStr(str, count)).toThrow(
48+
new Error("negative counts are not valid")
49+
);
4950
});

0 commit comments

Comments
 (0)