diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-a-text-alternative-to-images-for-visually-impaired-accessibility.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-a-text-alternative-to-images-for-visually-impaired-accessibility.english.md index f6d92fbbf9..d04abccb12 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-a-text-alternative-to-images-for-visually-impaired-accessibility.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-a-text-alternative-to-images-for-visually-impaired-accessibility.english.md @@ -26,7 +26,7 @@ Camper Cat happens to be both a coding ninja and an actual ninja, who is buildin ```yml tests: - text: Your img tag should have an alt attribute and it should not be empty. - testString: assert($('img').attr('alt'), 'Your img tag should have an alt attribute and it should not be empty.'); + testString: assert($('img').attr('alt')); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-an-accessible-date-picker.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-an-accessible-date-picker.english.md index 7933010abb..44ac3b0bc5 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-an-accessible-date-picker.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/add-an-accessible-date-picker.english.md @@ -30,13 +30,13 @@ Camper Cat is setting up a Mortal Kombat tournament and wants to ask his competi ```yml tests: - text: Your code should add one input tag for the date selector field. - testString: assert($('input').length == 2, 'Your code should add one input tag for the date selector field.'); + testString: assert($('input').length == 2); - text: Your input tag should have a type attribute with a value of date. - testString: assert($('input').attr('type') == 'date', 'Your input tag should have a type attribute with a value of date.'); + testString: assert($('input').attr('type') == 'date'); - text: Your input tag should have an id attribute with a value of pickdate. - testString: assert($('input').attr('id') == 'pickdate', 'Your input tag should have an id attribute with a value of pickdate.'); + testString: assert($('input').attr('id') == 'pickdate'); - text: Your input tag should have a name attribute with a value of date. - testString: assert($('input').attr('name') == 'date', 'Your input tag should have a name attribute with a value of date.'); + testString: assert($('input').attr('name') == 'date'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-carefully-choosing-colors-that-convey-information.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-carefully-choosing-colors-that-convey-information.english.md index a84e8708c1..c892af5269 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-carefully-choosing-colors-that-convey-information.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-carefully-choosing-colors-that-convey-information.english.md @@ -23,7 +23,7 @@ Camper Cat is testing different styles for an important button, but the yellow ( ```yml tests: - text: Your code should change the text color for the button to the dark blue. - testString: assert($('button').css('color') == 'rgb(0, 51, 102)', 'Your code should change the text color for the button to the dark blue.'); + testString: assert($('button').css('color') == 'rgb(0, 51, 102)'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-using-sufficient-contrast.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-using-sufficient-contrast.english.md index 980ce8a451..6c4e346467 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-using-sufficient-contrast.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/avoid-colorblindness-issues-by-using-sufficient-contrast.english.md @@ -24,9 +24,9 @@ Camper Cat is experimenting with using color for his blog text and background, b ```yml tests: - text: Your code should only change the lightness value for the text color property to a value of 15%. - testString: assert(code.match(/color:\s*?hsl\(0,\s*?55%,\s*?15%\)/gi), 'Your code should only change the lightness value for the text color property to a value of 15%.'); + testString: assert(code.match(/color:\s*?hsl\(0,\s*?55%,\s*?15%\)/gi)); - text: Your code should only change the lightness value for the background-color property to a value of 55%. - testString: assert(code.match(/background-color:\s*?hsl\(120,\s*?25%,\s*?55%\)/gi), 'Your code should only change the lightness value for the background-color property to a value of 55%.'); + testString: assert(code.match(/background-color:\s*?hsl\(120,\s*?25%,\s*?55%\)/gi)); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/give-links-meaning-by-using-descriptive-link-text.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/give-links-meaning-by-using-descriptive-link-text.english.md index b0d2fde5ef..ae05d2d11b 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/give-links-meaning-by-using-descriptive-link-text.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/give-links-meaning-by-using-descriptive-link-text.english.md @@ -22,9 +22,9 @@ The link text that Camper Cat is using is not very descriptive without the surro ```yml tests: - text: Your code should move the anchor a tags from around the words "Click here" to wrap around the words "information about batteries". - testString: assert($('a').text().match(/^(information about batteries)$/g), 'Your code should move the anchor a tags from around the words "Click here" to wrap around the words "information about batteries".'); + testString: assert($('a').text().match(/^(information about batteries)$/g)); - text: Make sure your a element has a closing tag. - testString: assert(code.match(/<\/a>/g) && code.match(/<\/a>/g).length === code.match(//g).length, 'Make sure your a element has a closing tag.'); + testString: assert(code.match(/<\/a>/g) && code.match(/<\/a>/g).length === code.match(//g).length); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-accessibility-of-audio-content-with-the-audio-element.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-accessibility-of-audio-content-with-the-audio-element.english.md index c2660accbb..457f3fa2e3 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-accessibility-of-audio-content-with-the-audio-element.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-accessibility-of-audio-content-with-the-audio-element.english.md @@ -33,19 +33,19 @@ Time to take a break from Camper Cat and meet fellow camper Zersiax (@zersiax), ```yml tests: - text: Your code should have one audio tag. - testString: assert($('audio').length === 1, 'Your code should have one audio tag.'); + testString: assert($('audio').length === 1); - text: Make sure your audio element has a closing tag. - testString: assert(code.match(/<\/audio>/g).length === 1 && code.match(/[\s\S]*<\/audio>/g), 'Make sure your audio element has a closing tag.'); + testString: assert(code.match(/<\/audio>/g).length === 1 && code.match(/[\s\S]*<\/audio>/g)); - text: The audio tag should have the controls attribute. - testString: assert($('audio').attr('controls'), 'The audio tag should have the controls attribute.'); + testString: assert($('audio').attr('controls')); - text: Your code should have one source tag. - testString: assert($('source').length === 1, 'Your code should have one source tag.'); + testString: assert($('source').length === 1); - text: Your source tag should be inside the audio tags. - testString: assert($('audio').children('source').length === 1, 'Your source tag should be inside the audio tags.'); + testString: assert($('audio').children('source').length === 1); - text: The value for the src attribute on the source tag should match the link in the instructions exactly. - testString: assert($('source').attr('src') === 'https://s3.amazonaws.com/freecodecamp/screen-reader.mp3', 'The value for the src attribute on the source tag should match the link in the instructions exactly.'); + testString: assert($('source').attr('src') === 'https://s3.amazonaws.com/freecodecamp/screen-reader.mp3'); - text: Your code should include a type attribute on the source tag with a value of audio/mpeg. - testString: assert($('source').attr('type') === 'audio/mpeg', 'Your code should include a type attribute on the source tag with a value of audio/mpeg.'); + testString: assert($('source').attr('type') === 'audio/mpeg'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-chart-accessibility-with-the-figure-element.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-chart-accessibility-with-the-figure-element.english.md index ab062c8e80..b4002bce85 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-chart-accessibility-with-the-figure-element.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-chart-accessibility-with-the-figure-element.english.md @@ -34,17 +34,17 @@ Camper Cat is hard at work creating a stacked bar chart showing the amount of ti ```yml tests: - text: Your code should have one figure tag. - testString: assert($('figure').length == 1, 'Your code should have one figure tag.'); + testString: assert($('figure').length == 1); - text: Your code should have one figcaption tag. - testString: assert($('figcaption').length == 1, 'Your code should have one figcaption tag.'); + testString: assert($('figcaption').length == 1); - text: Your code should not have any div tags. - testString: assert($('div').length == 0, 'Your code should not have any div tags.'); + testString: assert($('div').length == 0); - text: Your code should not have any p tags. - testString: assert($('p').length == 0, 'Your code should not have any p tags.'); + testString: assert($('p').length == 0); - text: The figcaption should be a child of the figure tag. - testString: assert($('figure').children('figcaption').length == 1, 'The figcaption should be a child of the figure tag.'); + testString: assert($('figure').children('figcaption').length == 1); - text: Make sure your figure element has a closing tag. - testString: assert(code.match(/<\/figure>/g) && code.match(/<\/figure>/g).length === code.match(/
/g).length, 'Make sure your figure element has a closing tag.'); + testString: assert(code.match(/<\/figure>/g) && code.match(/<\/figure>/g).length === code.match(/
/g).length); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-form-field-accessibility-with-the-label-element.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-form-field-accessibility-with-the-label-element.english.md index 71df772e98..52d53be6af 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-form-field-accessibility-with-the-label-element.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-form-field-accessibility-with-the-label-element.english.md @@ -32,9 +32,9 @@ Camper Cat expects a lot of interest in his thoughtful blog posts and wants to i ```yml tests: - text: Your code should have a for attribute on the label tag that is not empty. - testString: assert($('label').attr('for'), 'Your code should have a for attribute on the label tag that is not empty.'); + testString: assert($('label').attr('for')); - text: Your for attribute value should match the id value on the email input. - testString: assert($('label').attr('for') == 'email', 'Your for attribute value should match the id value on the email input.'); + testString: assert($('label').attr('for') == 'email'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-readability-with-high-contrast-text.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-readability-with-high-contrast-text.english.md index 0f450ac614..9f331485f1 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-readability-with-high-contrast-text.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/improve-readability-with-high-contrast-text.english.md @@ -22,9 +22,9 @@ Camper Cat's choice of light gray text on a white background for his recent blog ```yml tests: - text: Your code should change the text color for the body to the darker gray. - testString: assert($('body').css('color') == 'rgb(99, 99, 99)', 'Your code should change the text color for the body to the darker gray.'); + testString: assert($('body').css('color') == 'rgb(99, 99, 99)'); - text: Your code should not change the background-color for the body. - testString: assert($('body').css('background-color') == 'rgb(255, 255, 255)', 'Your code should not change the background-color for the body.'); + testString: assert($('body').css('background-color') == 'rgb(255, 255, 255)'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/jump-straight-to-the-content-using-the-main-element.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/jump-straight-to-the-content-using-the-main-element.english.md index 5319bbd44c..b5405993b8 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/jump-straight-to-the-content-using-the-main-element.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/jump-straight-to-the-content-using-the-main-element.english.md @@ -24,9 +24,9 @@ Camper Cat has some big ideas for his ninja weapons page. Help him set up his ma ```yml tests: - text: Your code should have one main tag. - testString: assert($('main').length == 1, 'Your code should have one main tag.'); + testString: assert($('main').length == 1); - text: The main tags should be between the closing header tag and the opening footer tag. - testString: assert(code.match(/<\/header>\s*?
\s*?<\/main>/gi), 'The main tags should be between the closing header tag and the opening footer tag.'); + testString: assert(code.match(/<\/header>\s*?
\s*?<\/main>/gi)); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/know-when-alt-text-should-be-left-blank.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/know-when-alt-text-should-be-left-blank.english.md index ddb1ba520e..6688eac899 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/know-when-alt-text-should-be-left-blank.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/know-when-alt-text-should-be-left-blank.english.md @@ -25,9 +25,9 @@ Camper Cat has coded a skeleton page for the blog part of his website. He's plan ```yml tests: - text: Your img tag should have an alt attribute. - testString: assert(!($('img').attr('alt') == undefined), 'Your img tag should have an alt attribute.'); + testString: assert(!($('img').attr('alt') == undefined)); - text: The alt attribute should be set to an empty string. - testString: assert($('img').attr('alt') == '', 'The alt attribute should be set to an empty string.'); + testString: assert($('img').attr('alt') == ''); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-elements-only-visible-to-a-screen-reader-by-using-custom-css.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-elements-only-visible-to-a-screen-reader-by-using-custom-css.english.md index d74ce0ecae..0beaaad1fb 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-elements-only-visible-to-a-screen-reader-by-using-custom-css.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-elements-only-visible-to-a-screen-reader-by-using-custom-css.english.md @@ -40,13 +40,13 @@ Camper Cat created a really cool stacked bar chart for his training page, and pu ```yml tests: - text: Your code should set the position property of the sr-only class to a value of absolute. - testString: assert($('.sr-only').css('position') == 'absolute', 'Your code should set the position property of the sr-only class to a value of absolute.'); + testString: assert($('.sr-only').css('position') == 'absolute'); - text: Your code should set the left property of the sr-only class to a value of -10000px. - testString: assert($('.sr-only').css('left') == '-10000px', 'Your code should set the left property of the sr-only class to a value of -10000px.'); + testString: assert($('.sr-only').css('left') == '-10000px'); - text: Your code should set the width property of the sr-only class to a value of 1 pixel. - testString: assert(code.match(/width:\s*?1px/gi), 'Your code should set the width property of the sr-only class to a value of 1 pixel.'); + testString: assert(code.match(/width:\s*?1px/gi)); - text: Your code should set the height property of the sr-only class to a value of 1 pixel. - testString: assert(code.match(/height:\s*?1px/gi), 'Your code should set the height property of the sr-only class to a value of 1 pixel.'); + testString: assert(code.match(/height:\s*?1px/gi)); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-links-navigable-with-html-access-keys.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-links-navigable-with-html-access-keys.english.md index d8e8e7c2a6..1e8e21e2e7 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-links-navigable-with-html-access-keys.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-links-navigable-with-html-access-keys.english.md @@ -24,13 +24,13 @@ Camper Cat wants the links around the two blog article titles to have keyboard s ```yml tests: - text: Your code should add an accesskey attribute to the a tag with the id of "first". - testString: assert($('#first').attr('accesskey'), 'Your code should add an accesskey attribute to the a tag with the id of "first".'); + testString: assert($('#first').attr('accesskey')); - text: Your code should add an accesskey attribute to the a tag with the id of "second". - testString: assert($('#second').attr('accesskey'), 'Your code should add an accesskey attribute to the a tag with the id of "second".'); + testString: assert($('#second').attr('accesskey')); - text: Your code should set the accesskey attribute on the a tag with the id of "first" to "g". Note that case matters. - testString: assert($('#first').attr('accesskey') == 'g', 'Your code should set the accesskey attribute on the a tag with the id of "first" to "g". Note that case matters.'); + testString: assert($('#first').attr('accesskey') == 'g'); - text: Your code should set the accesskey attribute on the a tag with the id of "second" to "c". Note that case matters. - testString: assert($('#second').attr('accesskey') == 'c', 'Your code should set the accesskey attribute on the a tag with the id of "second" to "c". Note that case matters.'); + testString: assert($('#second').attr('accesskey') == 'c'); ``` diff --git a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-screen-reader-navigation-easier-with-the-footer-landmark.english.md b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-screen-reader-navigation-easier-with-the-footer-landmark.english.md index df565d746c..c9c15a0d7b 100644 --- a/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-screen-reader-navigation-easier-with-the-footer-landmark.english.md +++ b/curriculum/challenges/english/01-responsive-web-design/applied-accessibility/make-screen-reader-navigation-easier-with-the-footer-landmark.english.md @@ -21,11 +21,11 @@ Camper Cat's training page is making good progress. Change the div ```yml tests: - text: Your code should have one footer tag. - testString: assert($('footer').length == 1, 'Your code should have one footer tag.'); + testString: assert($('footer').length == 1); - text: Your code should not have any div tags. - testString: assert($('div').length == 0, 'Your code should not have any div tags.'); + testString: assert($('div').length == 0); - text: Your code should have an opening and closing footer tag. - testString: assert(code.match(/