Package org.openqa.selenium

Examples of org.openqa.selenium.Platform


        count++;
      }
      if (caps.isJavascriptEnabled() == desired.isJavascriptEnabled()) {
        count++;
      }
      Platform capPlatform = caps.getPlatform();
      Platform desiredPlatform = desired.getPlatform();

      if (capPlatform != null && desiredPlatform != null) {
        if (capPlatform.is(desiredPlatform)) {
          count++;
        }
View Full Code Here


          "The specified path to the browser executable is invalid.");
    }
    this.browserInstallation = browserInstallation;

    // don't set the library path on Snow Leopard
    Platform platform = Platform.getCurrent();
    if (!platform.is(Platform.MAC) || ((platform.is(Platform.MAC)) && platform.getMajorVersion() <= 10 && platform.getMinorVersion() <= 5)) {
      shell.setLibraryPath(browserInstallation.libraryPath());
    }
    // Set MOZ_NO_REMOTE in order to ensure we always get a new Firefox process
    // http://blog.dojotoolkit.org/2005/12/01/running-multiple-versions-of-firefox-side-by-side
    shell.setEnvironmentVariable("MOZ_NO_REMOTE", "1");
View Full Code Here

        continue;
      }
      returnedCapabilities.setCapability(entry.getKey(), entry.getValue());
    }
    String platformString = (String) rawCapabilities.get("platform");
    Platform platform;
    try {
      if (platformString == null || "".equals(platformString)) {
        platform = Platform.ANY;
      } else {
        platform = Platform.valueOf(platformString);
View Full Code Here

  private static final int DEFAULT_SLEEP_TIMEOUT = 1000;
  private WebDriver driver;

  private boolean onPosix() {
    Platform current = Platform.getCurrent();
    switch (current) {
      case LINUX:
      case UNIX:
        return true;
      case MAC:
View Full Code Here

    }

    @Test
    public void should_resize_phantomjs_automatically() {
        Platform current = Platform.getCurrent();
        if (Platform.MAC.is(current)) {

            environmentVariables.setProperty("thucydides.browser.height", "200");
            environmentVariables.setProperty("thucydides.browser.width", "400");
View Full Code Here

TOP

Related Classes of org.openqa.selenium.Platform

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.