[Accessibility] Use id instead of children #254
Merged
Annotations
3 errors, 1 warning, and 1 notice
|
test/props.test.ts#L14
2) [webkit] › test/props.test.ts:11:7 › props › results match against custom filter ──────────────
Error: expect.toHaveAttribute: Error: strict mode violation: locator('[cmdk-item]') resolved to 2 elements:
1) <div cmdk-item="" role="option" id="radix-:Rqqm:" aria-disabled="false" aria-selected="false" data-disabled="false" data-selected="false">ant</div> aka getByLabel('Suggestions').getByText('ant', { exact: true })
2) <div cmdk-item="" role="option" id="radix-:R1aqm:" aria-disabled="false" aria-selected="false" data-disabled="false" data-selected="false">anteater</div> aka getByText('anteater')
Call log:
- expect.toHaveAttribute with timeout 5000ms
- waiting for locator('[cmdk-item]')
12 | await page.goto('/props?customFilter=true')
13 | await page.locator(`[cmdk-input]`).type(`ant`)
> 14 | await expect(page.locator(`[cmdk-item]`)).toHaveAttribute('data-value', 'ant')
| ^
15 | })
16 |
17 | test('controlled value', async ({ page }) => {
at /home/runner/work/cmdk/cmdk/test/props.test.ts:14:47
|
|
test/group.test.ts#L10
1) [webkit] › test/group.test.ts:8:7 › group › groups are shown/hidden based on item matches ─────
Error: expect(locator).not.toBeVisible()
Locator: locator('[cmdk-group][data-value="Animals"]')
Expected: not visible
Received: visible
Call log:
- expect.not.toBeVisible with timeout 5000ms
- waiting for locator('[cmdk-group][data-value="Animals"]')
8 × locator resolved to <div cmdk-group="" role="presentation" data-value="Animals">…</div>
- unexpected value "visible"
8 | test('groups are shown/hidden based on item matches', async ({ page }) => {
9 | await page.locator(`[cmdk-input]`).type('z')
> 10 | await expect(page.locator(`[cmdk-group][data-value="Animals"]`)).not.toBeVisible()
| ^
11 | await expect(page.locator(`[cmdk-group][data-value="Letters"]`)).toBeVisible()
12 | })
13 |
at /home/runner/work/cmdk/cmdk/test/group.test.ts:10:74
|
|
test/group.test.ts#L0
1) [webkit] › test/group.test.ts:8:7 › group › groups are shown/hidden based on item matches ─────
Test timeout of 5000ms exceeded.
|
|
|
|
|
The logs for this run have expired and are no longer available.
Loading