Skip to content

Can accept and dismiss alerts#101

Merged
matthewmcgarvey merged 1 commit intomasterfrom
alerts
Nov 19, 2020
Merged

Can accept and dismiss alerts#101
matthewmcgarvey merged 1 commit intomasterfrom
alerts

Conversation

@matthewmcgarvey
Copy link
Member

Fixes #67

One thing I was surprised by is that you cannot take screenshots if an alert is present. Some selenium libraries might implement functionality around taking a screenshot of the "browser" instead of just the element/window to get around this.

https://stackoverflow.com/questions/47693245/how-can-i-take-a-screenshot-of-an-alert-using-selenium-webdriver-in-ruby
https://stackoverflow.com/questions/21670361/capture-screenshot-of-alert

URI.parse(url).path
end

def accept_alert
Copy link
Member

Choose a reason for hiding this comment

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

What's the difference between these two methods? Since this isn't a confirm() modal, what are you "accept"ing?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think since it's an alert they do the same thing. If it was a confirm then it would do different things

Copy link
Member

Choose a reason for hiding this comment

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

ah. Ok

@matthewmcgarvey matthewmcgarvey merged commit 7f207c9 into master Nov 19, 2020
@matthewmcgarvey matthewmcgarvey deleted the alerts branch November 19, 2020 16:21
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.

Add #accept_alert and #dismiss_alert to LuckyFlow

2 participants