You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 3, 2020. It is now read-only.
I have a spec that passes when I use akephalos but fails using capybara-webkit.
Here's the gist of the scenario:
On the dashboard (logged in), if you delete a widget (link_to :method => delete, :remote => true...) then the event listener in coffeescript kinda like
$('.widgets a[data-method="delete"]').ajaxSuccess (event, xhr, settings) ->
# do some stuff
.ajaxError ->
alert "Borked"
should capture the successful deletion. However, capybara-webkit fails and I get an alert message "Borked". Manually testing this scenario confirms it works, as does running it with Akephalos. Sorry if this is a bit vague, but I can't easily extract an example from my client's app. Please let me know what info I can provide to help out. I'd love to switch to capybara-webkit. Saves ~ 30 seconds on each run over Akephalos!
The text was updated successfully, but these errors were encountered:
This happens because webkit actually opens an alert. Since capybara-webkit has direct access I think it should be possible to write something that can click ok in accepts.
In our current Selenium projects we use a helper like this:
def accept_alert(page)
page.execute_script('window.alert = function() { return true; }')
end
I tried executing that same function before and it didn't work, but I will give it another go. I looked around for an example that would click OK but I couldn't find anything.
I have a spec that passes when I use akephalos but fails using capybara-webkit.
Here's the gist of the scenario:
On the dashboard (logged in), if you delete a widget (link_to :method => delete, :remote => true...) then the event listener in coffeescript kinda like
should capture the successful deletion. However, capybara-webkit fails and I get an alert message "Borked". Manually testing this scenario confirms it works, as does running it with Akephalos. Sorry if this is a bit vague, but I can't easily extract an example from my client's app. Please let me know what info I can provide to help out. I'd love to switch to capybara-webkit. Saves ~ 30 seconds on each run over Akephalos!
The text was updated successfully, but these errors were encountered: