Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiedit e2e tests #4464

Merged
merged 52 commits into from
Aug 1, 2024
Merged

Conversation

dzonidoo
Copy link
Collaborator

@dzonidoo dzonidoo commented Apr 2, 2024

SDESK-7164

import {restoreDatabaseSnapshot, s} from './utils';

test.describe('Multiedit', async () => {
test('Can open article in multiedit', async ({page}) => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's no reason to test only opening. The main test should be opening 2 items(it is MULTI edit after all), changing a field, like headline, saving both, closing multi edit and seeing if changes persisted. If opening items in multi edit mode didn't work, the main test wouldn't pass either.

Copy link
Member

@tomaskikutis tomaskikutis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix tests first and then I take a look

import {restoreDatabaseSnapshot, s} from './utils';

test.describe('Multiedit', async () => {
test('Can edit articles in multiedit', async ({page}) => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix test names.

e2e/client/playwright/page-object-models/monitoring.ts Outdated Show resolved Hide resolved
e2e/client/playwright/page-object-models/monitoring.ts Outdated Show resolved Hide resolved
Comment on lines 37 to 41
await page.locator(s('multiedit-screen', 'multiedit-article=story 2')).hover();
await page
.locator(s('multiedit-screen', 'multiedit-article=story 2'))
.getByRole('button', {name: 'save'})
.click();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you create multi-edit helpers file and extract saving there?

@tomaskikutis tomaskikutis merged commit 8e04663 into superdesk:develop Aug 1, 2024
3 checks passed
tomaskikutis added a commit to tomaskikutis/superdesk-client-core that referenced this pull request Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants