MCPcopy Index your code
hub / github.com/adobe/react-spectrum / renderGrid

Function renderGrid

packages/react-aria/test/grid/useGrid.test.js:20–38  ·  view source on GitHub ↗
(props = {})

Source from the content-addressed store, hash-verified

18import userEvent from '@testing-library/user-event';
19
20function renderGrid(props = {}) {
21 return render(
22 <Grid {...props}>
23 <Item textValue="Item 1">
24 <Switch aria-label="Switch 1" />
25 <Switch aria-label="Switch 2" />
26 </Item>
27 <Item textValue="Item 2">
28 <Switch aria-label="Switch 3" />
29 <Switch aria-label="Switch 4" />
30 <Switch aria-label="Switch 5" />
31 </Item>
32 <Item textValue="Item 3">
33 <Switch aria-label="Switch 6" />
34 <Switch aria-label="Switch 7" />
35 </Item>
36 </Grid>
37 );
38}
39
40describe('useGrid', () => {
41 let user;

Callers 1

useGrid.test.jsFile · 0.85

Calls 1

renderFunction · 0.50

Tested by

no test coverage detected