Skip to content

Instantly share code, notes, and snippets.

@johan--
Forked from richdownie/headless ruby cukes
Created May 12, 2017 05:52
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 johan--/e22793308393074e158cc745ace2facd to your computer and use it in GitHub Desktop.
Save johan--/e22793308393074e158cc745ace2facd to your computer and use it in GitHub Desktop.
require 'cucumber'
require 'selenium-webdriver'
# require 'cukehub' # optional, but recommended. See cukehub.com for more details
caps = Selenium::WebDriver::Remote::Capabilities.chrome(chromeOptions: { binary: "/Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary",
args: [ "--headless" ]})
Before do
@browser = Selenium::WebDriver.for :chrome, desired_capabilities: caps
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment