From 590ca42c67ecf6130ac38a7b1005110a81407d7a Mon Sep 17 00:00:00 2001 From: Jason E Rush Date: Mon, 24 Apr 2017 07:50:14 -0800 Subject: [PATCH] Allow spaces in @mixins challenge (#14113) Allow space(s) between parenthesis and argument(s) in SASS function calls on the sass/create-reusable-css-with-mixins level. --- seed/challenges/03-front-end-libraries/sass.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/seed/challenges/03-front-end-libraries/sass.json b/seed/challenges/03-front-end-libraries/sass.json index ff348a547e2..7cb6986b6eb 100644 --- a/seed/challenges/03-front-end-libraries/sass.json +++ b/seed/challenges/03-front-end-libraries/sass.json @@ -166,12 +166,12 @@ " " ], "tests": [ - "assert(code.match(/@mixin\\s+?border-radius\\(\\$radius\\)\\s*?{/gi), 'message: Your code should declare a mixin named border-radius which has a parameter named $radius.');", + "assert(code.match(/@mixin\\s+?border-radius\\(\\s*?\\$radius\\s*?\\)\\s*?{/gi), 'message: Your code should declare a mixin named border-radius which has a parameter named $radius.');", "assert(code.match(/-webkit-border-radius:\\s*?\\$radius;/gi), 'message: Your code should include the -webkit-border-radius vender prefix that uses the $radius parameter.');", "assert(code.match(/-moz-border-radius:\\s*?\\$radius;/gi), 'message: Your code should include the -moz-border-radius vender prefix that uses the $radius parameter.');", "assert(code.match(/-ms-border-radius:\\s*?\\$radius;/gi), 'message: Your code should include the -ms-border-radius vender prefix that uses the $radius parameter.');", "assert(code.match(/border-radius:\\s*?\\$radius;/gi).length == 4, 'message: Your code should include the general border-radius rule that uses the $radius parameter.');", - "assert(code.match(/@include\\s+?border-radius\\(15px\\);/gi), 'message: Your code should call the border-radius mixin using the @include keyword, setting it to 15px.');" + "assert(code.match(/@include\\s+?border-radius\\(\\s*?15px\\s*?\\);/gi), 'message: Your code should call the border-radius mixin using the @include keyword, setting it to 15px.');" ], "solutions": [], "hints": [],