Merge pull request #9937 from dhcodes/fix/question-mark-in-alt-tag

Change test on Image Challenge to allow all char. in alt tag
This commit is contained in:
Mrugesh Mohapatra
2016-08-04 22:37:18 +05:30
committed by GitHub

View File

@ -1129,7 +1129,7 @@
"tests": [
"assert($(\"img\").length > 0, 'message: Your page should have an image element.');",
"assert(new RegExp(\"\\/\\/bit.ly\\/fcc-relaxing-cat\", \"gi\").test($(\"img\").attr(\"src\")), 'message: Your image should have a <code>src</code> attribute that points to the kitten image.');",
"assert(code.match(/alt\\s*?=\\s*?(\\\"|\\')[\\s\\w\\.\\,\\!]+?(\\\"|\\')/), 'message: Your image element <strong>must</strong> have an <code>alt</code> attribute.');"
"assert(code.match(/alt\\s*?=\\s*?(\\\"|\\').*(\\\"|\\')/), 'message: Your image element <strong>must</strong> have an <code>alt</code> attribute.');"
],
"type": "waypoint",
"challengeType": 0,