Repository navigation
Manchester | 26-ITP-Sept | Precious Moses | Sprint 3 | Sprint-3-Stretch-Exercises - #1737
moses77-boop wants to merge 35 commits into
Conversation
…ymbol requirement
| const password = "12345"; | ||
| const password = "Ab7xn"; |
There was a problem hiding this comment.
-
A valid password must meet all the requirements specified on lines 8-13. "Ab7xn" is not a valid password because it does not contain one of the required non-alphanumeric symbols.
-
isValidPassword()can returnfalseif the password fails to meet any one of the six requirements. To test whether the function correctly enforces requirement A, provide a password that satisfies all the other requirements but fails requirement A. This ensures that the test isolates and verifies requirement A specifically.Note: You don't have to check if the function can return
truein this category because you have already done that on lines 19-21.
| const password = "ab7#x"; | ||
| const result = isValidPassword(password); | ||
| expect(result).toEqual(true); | ||
| }); | ||
|
|
||
| test("password has at least one number", () => { | ||
| const password = "Ab7#x"; |
There was a problem hiding this comment.
The function should return false for these two passwords.
| const previousPassword = ["Ab7#x"]; | ||
| const result = isValidPassword(previousPassword); |
There was a problem hiding this comment.
What should be the first and second arguments of isValidPassword?
…g uppercase letters
Self checklist
Task code
CYF-1065
Changelist
In this PR, all exercises where attempted including implementing arrays, and playing-computer.