Merge pull request #10854 from Bouncey/Fix/UnmodifiedReturnStatement

Added test for unmodified return statement
This commit is contained in:
Logan Tegman
2016-10-16 14:00:33 -07:00
committed by GitHub

View File

@ -4634,6 +4634,7 @@
"assert(phoneticLookup(\"echo\") === 'Easy', 'message: <code>phoneticLookup(\"echo\")</code> should equal <code>\"Easy\"</code>');",
"assert(phoneticLookup(\"foxtrot\") === 'Frank', 'message: <code>phoneticLookup(\"foxtrot\")</code> should equal <code>\"Frank\"</code>');",
"assert(typeof phoneticLookup(\"\") === 'undefined', 'message: <code>phoneticLookup(\"\")</code> should equal <code>undefined</code>');",
"assert(code.match(/return\\sresult;/), 'message: You should not modify the <code>return</code> statement');",
"assert(!/case|switch|if/g.test(code), 'message: You should not use <code>case</code>, <code>switch</code>, or <code>if</code> statements'); "
],
"type": "waypoint",