Skip to content
This repository has been archived by the owner on Apr 8, 2024. It is now read-only.

Commit

Permalink
tests(core-suggest): verify visibility of all contents when input is …
Browse files Browse the repository at this point in the history
…cleared after filtering
  • Loading branch information
skjalgepalg committed Oct 26, 2023
1 parent 7d0b98f commit dcd1855
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions packages/core-suggest/core-suggest.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,18 @@ test.describe('core-suggest', () => {
await expect(coreSuggest.getByText('Suggest 1')).toBeHidden()
await expect(coreSuggest.getByText('Suggest 2')).toBeVisible()
await expect(coreSuggest.getByText('Suggest 3')).toBeHidden()
await expect(coreSuggest.getByText('Suggest 4')).toBeHidden()
})

test('filter is reset on clearing input value', async ({ page }) => {
await defaultTemplate(page)
await coreSuggestInput.fill('2')
await expect(coreSuggest.getByText('Suggest 1')).toBeHidden()
await coreSuggestInput.clear()
await expect(coreSuggest.getByText('Suggest 1')).toBeVisible()
await expect(coreSuggest.getByText('Suggest 2')).toBeVisible()
await expect(coreSuggest.getByText('Suggest 3')).toBeVisible()
await expect(coreSuggest.getByText('Suggest 4')).toBeVisible()
})

// TODO: Review assertions
Expand Down

0 comments on commit dcd1855

Please sign in to comment.