Created
July 31, 2013 16:30
-
-
Save ganta/6123642 to your computer and use it in GitHub Desktop.
Ghost DriverでUser-Agentを変更する設定
This file contains hidden or 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.phantomjs.PhantomJSDriver | |
import org.openqa.selenium.remote.DesiredCapabilities | |
driver = { | |
def capabilities = new DesiredCapabilities() | |
capabilities.setCapability( | |
'phantomjs.page.settings.userAgent', | |
'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)' | |
) | |
new PhantomJSDriver(capabilities) | |
} | |
reportsDir = 'reports' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment