Hi Isomorphic,
i try to get the TestRunnerDriver to work, to run Tests recorded with the Selenium IDE.
Setup:
SmartClient Version: v11.1p_2018-05-14/PowerEdition Deployment (built 2018-05-14)
Apache Tomcat v8.5
In our system i made a new Servlet SeleniumTests:
And created the Class for the Servlet:
When i then trigger the Servlet, the following console output is received:
=== 2018-05-21 12:12:29,093 [c-17] INFO RequestContext - URL: '/lms/SeleniumTests', User-Agent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36': Safari with Accept-Encoding header
=== 2018-05-21 12:12:29,093 [c-17] WARN TestRunnerConfiguration - Danger - ServletContext detected as org.apache.catalina.core.ApplicationContextFacade@1dca895b
=== 2018-05-21 12:12:29,093 [c-17] INFO TestRunnerConfiguration - Detected webRoot as C:/Program Files/Apache Software Foundation/Tomcat 8.5/lms/lms
=== 2018-05-21 12:12:29,093 [c-17] INFO TestRunnerConfiguration - Setting fileRoot to webRoot
=== 2018-05-21 12:12:29,094 [c-17] INFO SeleniumServerHelper - Selenium server starting on port: 4444
INFO | Writing debug logs to \tmp\selenium.log
INFO | Java: Oracle Corporation 25.144-b01
INFO | OS: Windows 10 10.0 amd64
INFO | v2.53.1, with Core v2.53.1. Built from revision a36b8b1
12:12:29.103 INFO - Driver class not found: com.opera.core.systems.OperaDriver
12:12:29.103 INFO - Driver provider com.opera.core.systems.OperaDriver is not registered
12:12:29.103 INFO - Driver provider org.openqa.selenium.safari.SafariDriver registration is skipped:
registration capabilities Capabilities [{browserName=safari, version=, platform=MAC}] does not match the current platform WIN10
12:12:29.103 INFO - Driver class not found: org.openqa.selenium.phantomjs.PhantomJSDriver
12:12:29.104 INFO - Driver provider org.openqa.selenium.phantomjs.PhantomJSDriver is not registered
12:12:29.104 INFO - Driver class not found: org.openqa.selenium.htmlunit.HtmlUnitDriver
12:12:29.104 INFO - Driver provider org.openqa.selenium.htmlunit.HtmlUnitDriver is not registered
INFO | Version Jetty/5.1.x
INFO | Started HttpContext[/selenium-server,/selenium-server]
INFO | Started org.openqa.jetty.jetty.servlet.ServletHandler@2d96b6f2
INFO | Started HttpContext[/wd,/wd]
INFO | Started HttpContext[/selenium-server/driver,/selenium-server/driver]
INFO | Started HttpContext[/,/]
INFO | Started SocketListener on 0.0.0.0:4444
INFO | Started org.openqa.jetty.jetty.Server@72ee89b2
=== 2018-05-21 12:12:29,108 [c-17] INFO SeleniumServerHelper - Selenium server started on port: 4444
INFO | Stopping Acceptor ServerSocket[addr=0.0.0.0/0.0.0.0,localport=4444]
INFO | Stopped SocketListener on 0.0.0.0:4444
INFO | Stopped HttpContext[/selenium-server,/selenium-server]
INFO | Stopped org.openqa.jetty.jetty.servlet.ServletHandler@2d96b6f2
INFO | Stopped HttpContext[/wd,/wd]
INFO | Stopped HttpContext[/selenium-server/driver,/selenium-server/driver]
INFO | Stopped HttpContext[/,/]
INFO | Stopped org.openqa.jetty.jetty.Server@72ee89b2
=== 2018-05-21 12:12:29,538 [c-17] INFO SeleniumServerHelper - Selenium server stopped
So, it seems to be working but does not execute the running.rctest.html. Can you give any advice?
Thanks in advance
Kind Regards
i try to get the TestRunnerDriver to work, to run Tests recorded with the Selenium IDE.
Setup:
SmartClient Version: v11.1p_2018-05-14/PowerEdition Deployment (built 2018-05-14)
Apache Tomcat v8.5
In our system i made a new Servlet SeleniumTests:
Code:
<servlet> <servlet-name>SeleniumTests</servlet-name> <servlet-class>com.lmscompany.lms.server.SeleniumTests</servlet-class> </servlet> <servlet-mapping> <servlet-name>SeleniumTests</servlet-name> <url-pattern>/SeleniumTests</url-pattern> </servlet-mapping>
Code:
public class SeleniumTests extends HttpServlet { private static final long serialVersionUID = -7397909713823548814L; @Override public void doGet(HttpServletRequest servletRequest, HttpServletResponse servletResponse) throws ServletException, IOException { TestRunnerDriver testRunner; try { testRunner = new TestRunnerDriver(); testRunner.setBatchCommit(false); testRunner.setBrowser("*firefox C:\\Program Files\\Mozilla Firefox\\firefox.exe"); testRunner.setTestRoot("/C:/Selenium/root/"); String[] files = { "running.rctest.html" }; testRunner.setFiles(files); testRunner.setMaximizeBrowser(true); testRunner.setNoEmail(); testRunner.run(); } catch (Exception e) { // TODO Auto-generated catch block e.printStackTrace(); } } @Override public void doPost(HttpServletRequest servletRequest, HttpServletResponse servletResponse) throws ServletException, IOException { doGet(servletRequest, servletResponse); } }
=== 2018-05-21 12:12:29,093 [c-17] INFO RequestContext - URL: '/lms/SeleniumTests', User-Agent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36': Safari with Accept-Encoding header
=== 2018-05-21 12:12:29,093 [c-17] WARN TestRunnerConfiguration - Danger - ServletContext detected as org.apache.catalina.core.ApplicationContextFacade@1dca895b
=== 2018-05-21 12:12:29,093 [c-17] INFO TestRunnerConfiguration - Detected webRoot as C:/Program Files/Apache Software Foundation/Tomcat 8.5/lms/lms
=== 2018-05-21 12:12:29,093 [c-17] INFO TestRunnerConfiguration - Setting fileRoot to webRoot
=== 2018-05-21 12:12:29,094 [c-17] INFO SeleniumServerHelper - Selenium server starting on port: 4444
INFO | Writing debug logs to \tmp\selenium.log
INFO | Java: Oracle Corporation 25.144-b01
INFO | OS: Windows 10 10.0 amd64
INFO | v2.53.1, with Core v2.53.1. Built from revision a36b8b1
12:12:29.103 INFO - Driver class not found: com.opera.core.systems.OperaDriver
12:12:29.103 INFO - Driver provider com.opera.core.systems.OperaDriver is not registered
12:12:29.103 INFO - Driver provider org.openqa.selenium.safari.SafariDriver registration is skipped:
registration capabilities Capabilities [{browserName=safari, version=, platform=MAC}] does not match the current platform WIN10
12:12:29.103 INFO - Driver class not found: org.openqa.selenium.phantomjs.PhantomJSDriver
12:12:29.104 INFO - Driver provider org.openqa.selenium.phantomjs.PhantomJSDriver is not registered
12:12:29.104 INFO - Driver class not found: org.openqa.selenium.htmlunit.HtmlUnitDriver
12:12:29.104 INFO - Driver provider org.openqa.selenium.htmlunit.HtmlUnitDriver is not registered
INFO | Version Jetty/5.1.x
INFO | Started HttpContext[/selenium-server,/selenium-server]
INFO | Started org.openqa.jetty.jetty.servlet.ServletHandler@2d96b6f2
INFO | Started HttpContext[/wd,/wd]
INFO | Started HttpContext[/selenium-server/driver,/selenium-server/driver]
INFO | Started HttpContext[/,/]
INFO | Started SocketListener on 0.0.0.0:4444
INFO | Started org.openqa.jetty.jetty.Server@72ee89b2
=== 2018-05-21 12:12:29,108 [c-17] INFO SeleniumServerHelper - Selenium server started on port: 4444
INFO | Stopping Acceptor ServerSocket[addr=0.0.0.0/0.0.0.0,localport=4444]
INFO | Stopped SocketListener on 0.0.0.0:4444
INFO | Stopped HttpContext[/selenium-server,/selenium-server]
INFO | Stopped org.openqa.jetty.jetty.servlet.ServletHandler@2d96b6f2
INFO | Stopped HttpContext[/wd,/wd]
INFO | Stopped HttpContext[/selenium-server/driver,/selenium-server/driver]
INFO | Stopped HttpContext[/,/]
INFO | Stopped org.openqa.jetty.jetty.Server@72ee89b2
=== 2018-05-21 12:12:29,538 [c-17] INFO SeleniumServerHelper - Selenium server stopped
So, it seems to be working but does not execute the running.rctest.html. Can you give any advice?
Thanks in advance
Kind Regards
Comment