We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6ee1609 commit 0ac1333Copy full SHA for 0ac1333
1 file changed
Sprint-3/2-practice-tdd/count.test.js
@@ -47,3 +47,10 @@ test("handles null or undefined source string", () => {
47
expect(countChar(null, char)).toEqual(0);
48
expect(countChar(undefined, char)).toEqual(0);
49
});
50
+
51
+test("returns 0 when stringOfCharacters is null or undefined", () => {
52
+ const char = "a";
53
54
+ expect(countChar(null, char)).toEqual(0);
55
+ expect(countChar(undefined, char)).toEqual(0);
56
+});
0 commit comments