Skip to content

Commit 6eac44d

Browse files
committed
update test to include null selectedKey
1 parent e8f8646 commit 6eac44d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/react-aria-components/stories/Tabs.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export default {
2525
export type TabsStory = StoryFn<typeof Tabs>;
2626

2727
export const TabsExample: TabsStory = () => {
28-
let [url, setUrl] = useState('/FoR');
28+
let [url, setUrl] = useState<string | null>(null);
2929

3030
return (
3131
<RouterProvider navigate={setUrl}>

packages/react-aria-components/test/Tabs.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,7 @@ describe('Tabs', () => {
487487
expect(tabs[2].tagName).toBe('A');
488488
expect(tabs[2]).toHaveAttribute('href', '/Emp');
489489

490-
expect(tabs[0]).toHaveAttribute('aria-selected', 'true');
490+
expect(tabs[1]).toHaveAttribute('aria-selected', 'false');
491491
await user.click(tabs[1]);
492492
expect(tabs[1]).toHaveAttribute('aria-selected', 'true');
493493

0 commit comments

Comments
 (0)