fix(challenges): Corrected a test case for challenge (#17162)

For the last test case in 'Access Props using this.props' challenge, I
updated the test condition to check that the value of the tempPassword
prop is the same as the content within the <strong/> tags. This test
case will ensure that there is text present in the strong tag and its
value is as expected.

BREAKING CHANGE: none

Closes #17134
pull/17269/head
manjeet5 2018-05-29 13:47:52 -04:00 committed by Quincy Larson
parent 6315c6eae0
commit 7bde8f266e
1 changed files with 1 additions and 1 deletions

View File

@ -1325,7 +1325,7 @@
},
{
"text": "The <code>ReturnTempPassword</code> component should display the password you create as the <code>tempPassword</code> prop within <code>strong</code> tags.",
"testString": "assert((function() { const mockedComponent = Enzyme.mount(React.createElement(ResetPassword)); return mockedComponent.find('strong').text() && mockedComponent.find('ReturnTempPassword').props().tempPassword; })(), 'The <code>ReturnTempPassword</code> component should display the password you create as the <code>tempPassword</code> prop within <code>strong</code> tags.');"
"testString": "assert((function() { const mockedComponent = Enzyme.mount(React.createElement(ResetPassword)); return mockedComponent.find('strong').text() === mockedComponent.find('ReturnTempPassword').props().tempPassword; })(), 'The <code>ReturnTempPassword</code> component should display the password you create as the <code>tempPassword</code> prop within <code>strong</code> tags.');"
}
],
"solutions": [