reactjs – check the internal state of the component using useState with enzyme

I am using the enzyme 3.9.0.

I just rephrased a class component to a component that uses the useState hook.

Previously I was testing the internal state of the component by extracting it in this way:

const shortcutActions = wrapper.state (). shortcuts;

expect (shortcutActions) .toHaveLength (1); 

Is it possible to consult the internal state when useState used?