diff --git a/test/unit-tests/accessibility/RovingTabIndex-test.tsx b/test/unit-tests/accessibility/RovingTabIndex-test.tsx index d3d75397b7..c814502732 100644 --- a/test/unit-tests/accessibility/RovingTabIndex-test.tsx +++ b/test/unit-tests/accessibility/RovingTabIndex-test.tsx @@ -120,6 +120,25 @@ describe("RovingTabIndex", () => { checkTabIndexes(container.querySelectorAll("button"), [-1, -1, 0]); }); + it("RovingTabIndexProvider provides a ref to the dom element", () => { + const nodeRef = React.createRef(); + const MyButton = (props: HTMLAttributes) => { + const [onFocus, isActive, ref] = useRovingTabIndex(nodeRef); + return