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

Plugin E2E: Replace magic strings with selectors #597

Merged
merged 21 commits into from
Dec 15, 2023

Conversation

sunker
Copy link
Contributor

@sunker sunker commented Dec 14, 2023

What this PR does / why we need it:

In this PR I'm replacing all remaining magic strings with proper selectors defined in e2e-selectors.

Which issue(s) this PR fixes:

Fixes #
Part of #576

Special notes for your reviewer:

Copy link

github-actions bot commented Dec 14, 2023

Hello! 👋 This repository uses Auto for releasing packages using PR labels.

✨ This PR can be merged. It will not be considered when calculating future versions of the npm packages and will not appear in the changelogs.

@sunker sunker mentioned this pull request Dec 14, 2023
6 tasks
@sunker sunker added the no-changelog Don't include in changelog and version calculations label Dec 14, 2023
@sunker sunker changed the title [WIP] Plugin E2E: Replace magic strings with selectors Plugin E2E: Replace magic strings with selectors Dec 14, 2023
@sunker sunker marked this pull request as ready for review December 14, 2023 13:45
@sunker sunker requested a review from a team as a code owner December 14, 2023 13:45
@sunker sunker requested review from oshirohugo, jackw, academo and a team and removed request for a team December 14, 2023 13:45
@sunker sunker force-pushed the plugin-e2e/refactor-selectors branch from e6c1b9b to 56f4609 Compare December 14, 2023 18:33
@@ -20,7 +20,7 @@ test('should load resources and display them as options when clicking on an inpu
await variableEditPage.datasource.set(provision.datasources?.[0]!.name!);
await page.getByLabel('Schema').click();
await expect(variableEditPage.getByTestIdOrAriaLabel('Select option')).toContainText(REDSHIFT_SCHEMAS);
await page.keyboard.press('Escape');
await page.keyboard.press('Enter');
Copy link
Member

Choose a reason for hiding this comment

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

Is this change intended?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes - In Grafana 9.2.x (and earlier), hitting Escape takes you away from dashboard settings and back to the dashboard start page. So needed some other command that can move focus away from the select, but still stay on the same page.

@sunker sunker merged commit 9f5ff89 into main Dec 15, 2023
18 checks passed
@sunker sunker deleted the plugin-e2e/refactor-selectors branch December 15, 2023 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog Don't include in changelog and version calculations
Projects
Development

Successfully merging this pull request may close these issues.

2 participants