From 44ff327a38e05a0e97d71d4b0e0bf6ed7bcd4408 Mon Sep 17 00:00:00 2001 From: Randell Dawson <5313213+RandellDawson@users.noreply.github.com> Date: Wed, 11 Dec 2019 20:20:19 -0800 Subject: [PATCH] fix(curriculum): make test more flexible for (#37902) * make test more robust * fix: changed test to ignore extra spaces in html * Revert "make test more robust" This reverts commit 89718eb5e5ceab90b78238af644e2ee77d854d69. --- .../react/render-a-class-component-to-the-dom.english.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/curriculum/challenges/english/03-front-end-libraries/react/render-a-class-component-to-the-dom.english.md b/curriculum/challenges/english/03-front-end-libraries/react/render-a-class-component-to-the-dom.english.md index 12f582cb793..878027ccd9b 100644 --- a/curriculum/challenges/english/03-front-end-libraries/react/render-a-class-component-to-the-dom.english.md +++ b/curriculum/challenges/english/03-front-end-libraries/react/render-a-class-component-to-the-dom.english.md @@ -30,7 +30,7 @@ tests: - text: The TypesOfFood component should render the Vegetables component after Fruits. testString: assert((function() { const mockedComponent = Enzyme.mount(React.createElement(TypesOfFood)); return mockedComponent.children().childAt(2).name() === 'Vegetables'; })()); - text: The TypesOfFood component should render to the DOM within the div with the id challenge-node. - testString: assert((function() { const html = document.getElementById('challenge-node').childNodes[0].innerHTML; return (html === '

Types of Food:

Fruits:

Non-Citrus:

Citrus:

Vegetables:

'); })()); + testString: assert((function() { const html = document.getElementById('challenge-node').childNodes[0].innerHTML; return html.includes('

Fruits:

Non-Citrus:

Citrus:

') && html.includes('

Vegetables:

'); })()); ```