Merge pull request #8958 from arun1595/fix/remainder-challenge-tests

Fix tests for finding remainder in javascript challenge
pull/18182/head
Eric Leung 2016-06-05 10:20:07 -07:00
commit 9c7d8d592c
1 changed files with 2 additions and 1 deletions

View File

@ -642,8 +642,9 @@
"var remainder = 11 % 3;"
],
"tests": [
"assert(/var\\s+?remainder/.test(code), 'message: The variable <code>remainder</code> should be initialized');",
"assert(remainder === 2, 'message: The value of <code>remainder</code> should be <code>2</code>');",
"assert(/var\\s*?remainder\\s*?=\\s*?.*%.*;/.test(code), 'message: You should use the <code>%</code> operator');"
"assert(/\\s+?remainder\\s*?=\\s*?.*%.*;/.test(code), 'message: You should use the <code>%</code> operator');"
],
"type": "waypoint",
"challengeType": 1,