Created
October 28, 2018 11:54
-
-
Save tiagogomes772/acd027f9323560a72e9d8b007b9c3cb4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it('renders random advice', () => { | |
const app = shallow(<App advice='Random Advice' fetching={false} />); | |
console.log("HERE", app.debug()); | |
expect(app.instance().defineLabelAdvice()).toEqual('This is a random advice'); | |
expect(app).toMatchSnapshot(); | |
}); | |
it('renders input based advice', () => { | |
const app = shallow(<App advice='Input Advice' fetching={false} />); | |
app.setState({ value: 'spider' }); | |
console.log("HERE", app.debug()); | |
expect(app.instance().defineLabelAdvice()).toEqual('This is a advice based on the input:'); | |
expect(app).toMatchSnapshot(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment