Enzyme check if component mounted without errors on prop types

Viewed 646

I am creating integration test for a components to test its interface and I am mounting it like so

const wrapper = shallow(<Component boolVal={()=>{}} />

In the Component I have marked boolVal prop as boolean value and when mounting I am getting an expected warning:

`Warning: Failed prop type: Invalid prop `boolVal` of type `function` supplied to `Component`, expected `boolean`.`

This is correct, but I'd like the test to fail.

How can I archive this please?

1 Answers
Related