Fix test case so only the word submit can pass test

This commit is contained in:
Christian Lapinig
2016-02-25 01:15:16 -08:00
parent 2d25a55882
commit 7d82b0776d

View File

@ -1765,7 +1765,7 @@
"tests": [ "tests": [
"assert($(\"form\").children(\"button\").length > 0, 'message: Your form should have a button inside it.');", "assert($(\"form\").children(\"button\").length > 0, 'message: Your form should have a button inside it.');",
"assert($(\"button\").attr(\"type\") === \"submit\", 'message: Your submit button should have the attribute <code>type</code> set to <code>submit</code>.');", "assert($(\"button\").attr(\"type\") === \"submit\", 'message: Your submit button should have the attribute <code>type</code> set to <code>submit</code>.');",
"assert($(\"button\").text().match(/submit/gi), 'message: Your submit button should have the text \"Submit\".');", "assert($(\"button\").text().match(/^\\s*submit\\s*$/gi), 'message: Your submit button should only have the text \"Submit\".');",
"assert(code.match(/<\\/button>/g) && code.match(/<button/g) && code.match(/<\\/button>/g).length === code.match(/<button/g).length, 'message: Make sure your <code>button</code> element has a closing tag.');" "assert(code.match(/<\\/button>/g) && code.match(/<button/g) && code.match(/<\\/button>/g).length === code.match(/<button/g).length, 'message: Make sure your <code>button</code> element has a closing tag.');"
], ],
"challengeType": 0, "challengeType": 0,