File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
exercises/07-Very-Specific-Rules Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ describe("All the styles should be applied", ()=>{
2626 }
2727 let reg = new RegExp ( / c o l o r : \s * r e d \s * ! i m p o r t a n t \s * ; / gm)
2828
29- expect ( reg . test ( color ) ) . toBeTruthy ( ) ;
29+ expect ( reg . test ( color . toLowerCase ( ) ) ) . toBeTruthy ( ) ;
3030 } ) ;
3131
3232 test ( "The ol second element background should be green" , ( ) => {
@@ -44,6 +44,14 @@ describe("All the styles should be applied", ()=>{
4444
4545 }
4646
47+ if ( background ) {
48+ background = background . toLowerCase ( )
49+ }
50+
51+ if ( backgroundColor ) {
52+ backgroundColor = backgroundColor . toLowerCase ( )
53+ }
54+
4755 } expect ( background === 'green' || backgroundColor === 'green' ) . toBeTruthy ( ) ;
4856 } )
4957
@@ -62,7 +70,7 @@ describe("All the styles should be applied", ()=>{
6270
6371 }
6472
65- } expect ( background === "yellow" || backgroundColor === "yellow" ) . toBeTruthy ( ) ;
73+ } expect ( background . toLowerCase ( ) === "yellow" || backgroundColor . toLowerCase ( ) === "yellow" ) . toBeTruthy ( ) ;
6674 } )
6775
6876 test ( "Write all your rules above the existing code" , ( ) => {
You can’t perform that action at this time.
0 commit comments