Created
April 3, 2018 14:03
-
-
Save wooyoung85/ec3ed3084ad16f85a176f8f2bf5b0310 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.openqa.selenium.chrome.ChromeDriver | |
import org.openqa.selenium.chrome.ChromeOptions | |
import org.openqa.selenium.firefox.FirefoxDriver | |
waiting { | |
timeout = 2 | |
} | |
environments { | |
// run via “./gradlew chromeTest” | |
// See: http://code.google.com/p/selenium/wiki/ChromeDriver | |
chrome { | |
driver = { new ChromeDriver() } | |
} | |
// run via “./gradlew chromeHeadlessTest” | |
// See: http://code.google.com/p/selenium/wiki/ChromeDriver | |
chromeHeadless { | |
driver = { | |
ChromeOptions o = new ChromeOptions() | |
o.addArguments('headless') | |
new ChromeDriver(o) | |
} | |
} | |
// run via “./gradlew firefoxTest” | |
// See: http://code.google.com/p/selenium/wiki/FirefoxDriver | |
firefox { | |
atCheckWaiting = 1 | |
driver = { new FirefoxDriver() } | |
} | |
} | |
// To run the tests with all browsers just run “./gradlew test” | |
baseUrl = "http://localhost:8080" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment