File file = new File("phantom,.exe_file"); System.setProperty("phantomjs.binary.path", file.getAbsolutePath()); new DesiredCapabilities(); DesiredCapabilities desiredCapabilities = DesiredCapabilities.phantomjs(); desiredCapabilities.setJavascriptEnabled(true); // turn off logging ArrayList<String> cliArgsCap = new ArrayList<String>(); cliArgsCap.add("--webdriver-loglevel=NONE"); desiredCapabilities.setCapability(PhantomJSDriverService.PHANTOMJS_CLI_ARGS, cliArgsCap); Logger.getLogger(PhantomJSDriverService.class.getName()).setLevel(Level.OFF); driver = new PhantomJSDriver(desiredCapabilities);
Wednesday, April 27, 2016
Phantom JS
Implement phantomJS with logger OFF
Labels:
Selenium
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment