Skip to content

Commit

Permalink
test(SLB-328): update e2e tests
Browse files Browse the repository at this point in the history
  • Loading branch information
chindris committed May 7, 2024
1 parent cd04cfa commit 873815a
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/e2e/specs/drupal/content-editing.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,21 @@ test.describe('content-editing', () => {
test.use({ storageState: '.auth/admin.json' });

test('moderation controls are placed in the sidebar', async ({ page }) => {
await page.goto(cmsUrl('/node/add/page'));
await page.goto(cmsUrl('/drupal'));
await page.locator('li.tabs__tab a:text("Edit")').click();
await expect(
page.locator('[aria-label="Editor settings"]').getByText('Save as'),
page.locator('[aria-label="Editor settings"]').getByText('Change to'),
).toBeVisible();
});

test('"More settings" fieldset is removed', async ({ page }) => {
await page.goto(cmsUrl('/drupal'));
await page.locator('li.tabs__tab a:text("Edit")').click();
// Why we expect it to be removed:
// - It's too long to scroll to the bottom of long pages
// - If we have any valuable controls in the "More settings" fieldset,
// we should move them to the sidebar, where they are much easier to
// access
await page.goto(cmsUrl('/node/add/page'));
await expect(page.locator(':text-is("More settings")')).toHaveCount(0);
});
});

0 comments on commit 873815a

Please sign in to comment.