Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@ggarnier
Created August 5, 2015 19:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ggarnier/ffd22d4e0a9c06725b49 to your computer and use it in GitHub Desktop.
Save ggarnier/ffd22d4e0a9c06725b49 to your computer and use it in GitHub Desktop.
Capybara - list requested domains
page.driver.network_traffic.map do |req|
req.url.gsub(/^(https?:\/\/[^\/]+)\/.*$/, '\1')
end.uniq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment