| 1227 | const TreeExample = comp === 'DynamicSectionTree' ? DynamicSectionTree : DynamicTree; |
| 1228 | |
| 1229 | function getAllRows(tree: HTMLElement) { |
| 1230 | const rowGroups = within(tree).queryAllByRole('rowgroup'); |
| 1231 | return rowGroups.length > 0 |
| 1232 | ? rowGroups.flatMap(rowGroup => within(rowGroup).queryAllByRole('row').slice(1)) |
| 1233 | : within(tree).queryAllByRole('row'); |
| 1234 | } |
| 1235 | |
| 1236 | it('left and right arrows should navigate between interactive elements in the row', async () => { |
| 1237 | let {getByRole} = render(<TreeExample treeProps={{selectionMode: 'multiple'}} />); |