fix(challenges): add test to lookahead regex challenge

ISSUES CLOSED: #209
This commit is contained in:
Josh Alling 2018-08-02 13:42:52 -06:00 committed by Kristofer Koishigawa
parent 31957a45e2
commit e044de4230

View File

@ -1517,6 +1517,10 @@
"text": "Your regex should not match <code>\"airplanes\"</code>",
"testString": "assert(!pwRegex.test(\"airplanes\"), 'Your regex should not match <code>\"airplanes\"</code>');"
},
{
"text": "Your regex should not match <code>\"banan1\"</code>",
"testString": "assert(!pwRegex.test(\"banan1\"), 'Your regex should not match <code>\"banan1\"</code>');"
},
{
"text": "Your regex should match <code>\"bana12\"</code>",
"testString": "assert(pwRegex.test(\"bana12\"), 'Your regex should match <code>\"bana12\"</code>');"
@ -1534,7 +1538,7 @@
"testString": "assert(!pwRegex.test(\"1234\"), 'Your regex should not match <code>\"1234\"</code>');"
}
],
"solutions": [],
"solutions": ["var pwRegex = /(?=\\w{5})(?=\\D*\\d{2})/;"],
"hints": [],
"releasedOn": "Feb 17, 2017",
"challengeType": 1,