added test to check if the string matches exactly
This commit is contained in:
committed by
Berkeley Martinez
parent
faca93d1f5
commit
4504cab299
@ -816,7 +816,8 @@
|
|||||||
"var myStr = \"I am a \\\"double quoted\\\" string inside \\\"double quotes\\\"\";"
|
"var myStr = \"I am a \\\"double quoted\\\" string inside \\\"double quotes\\\"\";"
|
||||||
],
|
],
|
||||||
"tests": [
|
"tests": [
|
||||||
"assert(code.match(/\\\\\"/g).length === 4 && code.match(/[^\\\\]\"/g).length === 2, 'message: You should use two double quotes (<code>"</code>) and four escaped double quotes (<code>\"</code>) ');"
|
"assert(code.match(/\\\\\"/g).length === 4 && code.match(/[^\\\\]\"/g).length === 2, 'message: You should use two double quotes (<code>"</code>) and four escaped double quotes (<code>\"</code>) ');",
|
||||||
|
"assert(myStr === \"I am a \\\"double quoted\\\" string inside \\\"double quotes\\\"\", 'message: Variable myStr should equal to (<code>\"I am a \"double quoted\" string inside \"double quotes\"\"</code>).');"
|
||||||
],
|
],
|
||||||
"type": "waypoint",
|
"type": "waypoint",
|
||||||
"challengeType": 1
|
"challengeType": 1
|
||||||
|
Reference in New Issue
Block a user