diff --git a/curriculum/challenges/english/03-front-end-libraries/react/write-a-react-component-from-scratch.english.md b/curriculum/challenges/english/03-front-end-libraries/react/write-a-react-component-from-scratch.english.md index e19464b739..d97aa539c9 100644 --- a/curriculum/challenges/english/03-front-end-libraries/react/write-a-react-component-from-scratch.english.md +++ b/curriculum/challenges/english/03-front-end-libraries/react/write-a-react-component-from-scratch.english.md @@ -29,7 +29,8 @@ tests: testString: assert((function() { const mockedComponent = Enzyme.mount(React.createElement(MyComponent)); return mockedComponent.find('h1').text() === 'My First React Component!'; })()); - text: MyComponent should render to the DOM. testString: assert(document.getElementById('challenge-node').childNodes.length === 1); - + - text: MyComponent should have a constructor calling super with props. + testString: assert(MyComponent.toString().includes('MyComponent(props)') && MyComponent.toString().includes('_super.call(this, props)')); ```