Skip to content

Commit

Permalink
fix: integration test fixes - discrepancies in text values
Browse files Browse the repository at this point in the history
  • Loading branch information
awesthouse committed Jun 25, 2024
1 parent f1776cc commit 7427c7d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions e2e/tests/plugin-list-task_list.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ test('task list', async ({ page }) => {
).toHaveValue('Wash the car')
await contentWrapper.getByText('Mark task as complete').click()
await contentWrapper.getByRole('button', { name: 'Submit' }).click()
await expect(
contentWrapper.getByRole('button', { name: 'Submit' })
).toBeDisabled()
await expect(page.getByRole('alert')).toHaveText(['Document updated'])
await page.getByLabel('Close task_list').click()
await page.getByTestId('task_list').getByLabel('Open in tab').click()
Expand Down
4 changes: 2 additions & 2 deletions e2e/tests/plugin-view_selector-car_garage.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ test('View selector - car garage', async ({ page }) => {

await test.step('Collapse and expand sidebar', async () => {
await page.getByRole('tab', { name: 'Self' }).click()
await page.getByRole('button', { name: 'Collapse' }).click()
await page.getByRole('button', { name: 'Collapse item' }).click()
await expect(page.getByRole('tab', { name: 'Self' })).not.toBeVisible()
await expect(page.getByRole('tab', { name: 'Audi' })).not.toBeVisible()
await expect(page.getByRole('tab', { name: 'Volvo' })).not.toBeVisible()
Expand All @@ -23,7 +23,7 @@ test('View selector - car garage', async ({ page }) => {
)
await page.getByRole('tab').first().click()
await expect(page.getByLabel('Name')).toHaveValue('CarGarage')
await page.getByRole('button', { name: 'Expand' }).click()
await page.getByRole('button', { name: 'Expand item' }).click()
await expect(page.getByRole('tab', { name: 'Self' })).toBeVisible()
await expect(page.getByRole('tab', { name: 'Audi' })).toBeVisible()
await expect(page.getByRole('tab', { name: 'Volvo' })).toBeVisible()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export function getMenuItems(
const menuItems = []
const getMenuItem = (id: EDialog, text: string) => {
return (
<Menu.Item key={id} onClick={() => setDialogId(id)}>
<Menu.Item key={id} onClick={() => setDialogId(id)} aria-label={text}>
{text}
</Menu.Item>
)
Expand Down

0 comments on commit 7427c7d

Please sign in to comment.