I've recently started upgrading my current React 16 and 17 projects to React 18. Consequently, I had to change my testing library from Enzym to React Testing Library (RTL). I came across a scenario where I can't find an equivalent. I'm using material-ui as the style library. In Enzyme I can query the component like this:
const wrapper = shallow(<InitialForm />);
const moreButton = wrapper.find(MoreMenu);
expect(moreButton.props().disabled).toBe(true);
I'm looking for something similar to this in the RTL. I tried the findByRole also but it does not give similar output.
Thanks in advance.