@@ -17,29 +17,29 @@ You must breakdown this problem in order to solve it. Find one test case first a
1717const isValidPassword = require ( "./password-validator" ) ;
1818
1919describe ( "passwordValidator" , ( ) => {
20- const password = "123Ab*" ;
20+ const validPassword = "123Ab*" ;
2121
2222 test ( "returns true for passwords with at least 5 characters" , ( ) => {
23- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
23+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
2424 } ) ;
2525
2626 test ( "return true for passwords with at least one uppercase letter" , ( ) => {
27- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
27+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
2828 } ) ;
2929
3030 test ( "return true for passwords with at least one lowercase letter" , ( ) => {
31- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
31+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
3232 } ) ;
3333
3434 test ( "return true for passwords with at least one number" , ( ) => {
35- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
35+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
3636 } ) ;
3737
3838 test ( "return true for passwords with at least one non-alphanumeric symbol" , ( ) => {
39- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
39+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
4040 } ) ;
4141
4242 test ( "return true for passwords that are not in the previous passwords array" , ( ) => {
43- expect ( isValidPassword ( password ) ) . toBe ( true ) ;
43+ expect ( isValidPassword ( validPassword ) ) . toBe ( true ) ;
4444 } ) ;
4545} ) ;
0 commit comments