fix(challenge): check inline style for color (#38211)
* fix(challenge): check inline style for color * Update curriculum/challenges/english/01-responsive-web-design/basic-css/change-the-color-of-text.english.md Co-Authored-By: Parth Parth <34807532+thecodingaviator@users.noreply.github.com> Co-authored-by: Parth Parth <34807532+thecodingaviator@users.noreply.github.com>
This commit is contained in:
@ -28,8 +28,8 @@ Change your <code>h2</code> element's style so that its text color is red.
|
||||
tests:
|
||||
- text: Your <code>h2</code> element should have a <code>style</code> declaration.
|
||||
testString: assert($("h2").attr('style'));
|
||||
- text: Your <code>h2</code> element should be red.
|
||||
testString: assert($("h2").css("color") === "rgb(255, 0, 0)");
|
||||
- text: Your <code>h2</code> element should have color set to <code>red</code>.
|
||||
testString: assert($("h2")[0].style.color === "red");
|
||||
- text: Your <code>style</code> declaration should end with a <code>;</code> .
|
||||
testString: assert($("h2").attr('style') && $("h2").attr('style').endsWith(';'));
|
||||
|
||||
|
Reference in New Issue
Block a user