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

fix safari scroll #1663

Merged
merged 18 commits into from
Mar 30, 2023
Merged

fix safari scroll #1663

merged 18 commits into from
Mar 30, 2023

Conversation

maskin25
Copy link
Contributor

@maskin25 maskin25 commented Mar 30, 2023

What this PR does

Fix scroll in Safari

Which issue(s) this PR fixes

#415

Checklist

  • Unit, integration, and e2e (if applicable) tests updated
  • Documentation added (or pr:no public docs PR label added if not required)
  • CHANGELOG.md updated (or pr:no changelog PR label added if not required)

@maskin25 maskin25 added pr:no changelog pr:no public docs Added to a PR that does not require public documentation updates labels Mar 30, 2023
@maskin25 maskin25 requested a review from a team March 30, 2023 07:46
Copy link
Contributor

@joeyorlando joeyorlando left a comment

Choose a reason for hiding this comment

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

can you uncomment out the Safari browser in the e2e tests here?

@maskin25
Copy link
Contributor Author

@joeyorlando I enabled tests on Safari

@joeyorlando joeyorlando requested a review from a team March 30, 2023 11:33
CHANGELOG.md Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
@maskin25 maskin25 force-pushed the maxim/fix-safari-scrolling branch from 009580e to 73265da Compare March 30, 2023 13:35
@@ -39,7 +39,7 @@ export const clickButton = async ({
dataTestId,
}: ClickButtonArgs): Promise<void> => {
const baseLocator = dataTestId ? `button[data-testid="${dataTestId}"]` : 'button';
const button = (startingLocator || page).locator(`${baseLocator} >> text=${buttonText}`);
const button = (startingLocator || page).locator(`${baseLocator}:not([disabled]) >> text=${buttonText}`);
Copy link
Contributor

@joeyorlando joeyorlando Mar 30, 2023

Choose a reason for hiding this comment

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

this should make some of the flaky schedules tests more reliable.. I think the issue was that the tests were trying to click on the "Add rotation" button, which according to this screenshot, starts off disabled. So it would click the disabled button and then expect for something to become available.. but obviously it wouldn't because the button click did nothing.

By adding this, Playwright should wait until the desired button is enabled before trying to click it:
Screenshot 2023-03-30 at 16 12 25

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hmm, create rotation button is disabled when creation form is already opened and it's always disabled for non-web schedules, i'm not sure what happened in that case...

@joeyorlando joeyorlando added this pull request to the merge queue Mar 30, 2023
Merged via the queue into dev with commit 11d6224 Mar 30, 2023
@joeyorlando joeyorlando deleted the maxim/fix-safari-scrolling branch March 30, 2023 18:23
brojd pushed a commit that referenced this pull request Sep 18, 2024
# What this PR does

Fix  scroll in Safari

## Which issue(s) this PR fixes

#415

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)

---------

Co-authored-by: Joey Orlando <joseph.t.orlando@gmail.com>
Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:no public docs Added to a PR that does not require public documentation updates
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants