()
| 105 | it('should error if component does not forward its ref', async function () { |
| 106 | using spy = jest.spyOn(console, 'error').mockImplementation(() => {}); |
| 107 | let Component = () => <span role="button">Hi</span>; |
| 108 | render( |
| 109 | <Focusable> |
| 110 | <Component>Button</Component> |
| 111 | </Focusable> |
| 112 | ); |
| 113 | |
| 114 | expect(spy).toHaveBeenCalledWith('<Focusable> child must forward its ref to a DOM element.'); |
| 115 | }); |