manifoldcf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kish...@apache.org
Subject svn commit: r1788717 - /manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java
Date Sun, 26 Mar 2017 11:32:52 GMT
Author: kishore
Date: Sun Mar 26 11:32:52 2017
New Revision: 1788717

URL: http://svn.apache.org/viewvc?rev=1788717&view=rev
Log:
Added selenium test support for Internet Explorer.

Modified:
    manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java

Modified: manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java
URL: http://svn.apache.org/viewvc/manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java?rev=1788717&r1=1788716&r2=1788717&view=diff
==============================================================================
--- manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java
(original)
+++ manifoldcf/trunk/framework/core/src/test/java/org/apache/manifoldcf/core/tests/SeleniumTester.java
Sun Mar 26 11:32:52 2017
@@ -30,6 +30,7 @@ import org.openqa.selenium.WebElement;
 import org.openqa.selenium.chrome.ChromeDriver;
 import org.openqa.selenium.chrome.ChromeOptions;
 import org.openqa.selenium.firefox.FirefoxDriver;
+import org.openqa.selenium.ie.InternetExplorerDriver;
 import org.openqa.selenium.support.ui.ExpectedCondition;
 import org.openqa.selenium.support.ui.ExpectedConditions;
 import org.openqa.selenium.support.ui.Select;
@@ -47,7 +48,8 @@ public class SeleniumTester
   public enum BrowserType
   {
     CHROME,
-    FIREFOX
+    FIREFOX,
+    IE
   }
 
   /**
@@ -92,6 +94,15 @@ public class SeleniumTester
         //Create a new instance of Firefox driver
         driver = new FirefoxDriver();
         break;
+      case IE:
+        if(System.getProperty("webdriver.ie.driver") == null
+                || System.getProperty("webdriver.ie.driver").length() == 0)
+          throw new IllegalStateException(
+                  "Please configure your SL_IE_DRIVER environment variable to point to the
Internet Explorer Driver");
+
+        //For more info, on how to configure IE driver, plese read https://github.com/SeleniumHQ/selenium/wiki/InternetExplorerDriver
+        driver = new InternetExplorerDriver();
+        break;
       default:
         throw new IllegalArgumentException("Unknown browser type");
     }



Mime
View raw message