how can I check if selenium server is running and start selenium if it is not running. I get the error connection refused often when integrated selenium tests into jenkins. Obviously, I want to give selenium a chance to get started because running my tests. What's the proper bash command to get this done?
Would this answer be of help to you? Basically it recommends you hit a url (e.g. http://localhost:4444/selenium-server/driver?cmd=getLogMessages) to see if the server is running.
Related
We are on a mission to run our acceptance tests from a selenium container running different browsers in their own containers and we have set things up so minimal config changes are necessary when testing on a local machine or a remote one triggered by continuous integration.
The stumbling block I have hit is that the site under test is authorised through windows authentication and the chrome container is effectively running as a different machine, which means that when WebDriver serves up the site it is prompted with a log in box.
So far I have run into dead ends with every technique I have used to get round this.
I can't send the credentials in the uri as many older posts suggest - just doesn't work. I can't use AutoIt to populate the auth window as the window is in a container and that runs in linux. Finally had no joy trying to proxy from one server to test server, for what ever reasons the credentials are not recognised that I set up in the proxy (using for example cntlm proxy tool).
Is this mission impossible or is there any way round this?
I want to do performance test of my website with the help of Jmeter. i have installed Jmeter version 3.3 and did all the set up with reference of below website. I have done all proxy setting of Jmeter and in browser.
Pdf step by step
But while recording the script, browser does not allow to run the website on Jmeter proxy and gives "java.net.ConnectException: Connection timed out" error.
Please guide.
You most probably didn’t configure the enterprise proxy on JMeter:
http://jmeter.apache.org/usermanual/get-started.html#proxy_server
I am attempting to write an automation script for a process on a website using PhantomJS. I have done this same type of automation many times before, but I am having trouble with this one particular website that uses Oracle Access Manager.
When I log in with Chrome or any other desktop browser, I have no problems. However, when I try to log in with the headless browser I receive an OAM9 error which is very unspecific "for security reasons"
I have tried changing the user agent string and ignoring bad ssl certificates, I am running out of ideas and my higher ups promised this functionality to someone. Any help would be appreciated.
I have installed Oracle AS 10.1.3.1 and then applied patch to upgrade it to 10.1.3.4
This OAS is configured to listen at port 80.
When I go to http://localhost after starting OPMN, i can wee the welcome screen.
But now I want to login to Enterprise Manager(em) console so I go to http://localhost/em
but this link doesn't work and says:
Not Found The requested URL /em was
not found on this server.
Please tell me how to start em console in OAS 10.1.3.4
Firstly to verify what port you should be using (and providing you haven't reconfigured it) you can check the file:
portlist.ini
which can be found at
ORACLE_APPLICATION_SERVER_HOME\install
Once you are sure that you are using the correct port, have you started the console? (opmnctl start all command doesn't start the AS control) You can try starting it using the following command:
ORACLE_APPLICATION_SERVER_HOME\opmn\bin\opmnctl startproc application=ascontrol
I'm casting my mind back a few years here, so this could be completely wrong.
I think that em had it's own web-server and so would have run on a different port. Try 1810.
You might also want to try https rather than http.
So, in conclusion, try:
http://localhost:1810/em
https://localhost:1810/em
If this doesn't work, please can you let me know and I'll delete this answer. :-)
I and my colleagues have an intermittent problem running junit tests or tomcat from within Eclipse.
Sometimes the tests will run.
Sometimes they will not.
There appears to be no pattern and we are not in sync. IE mine might run and others will fail.
Stopping/starting Eclipse can resolve the issue (sometimes).
Pulling out the network cable ALWAYS resolves the problem (while it is out).
When it fails the following happens.
On trying to run the class the Console screen appears with the red box.
The console screen stays blank for about 30 seconds and then the following appears:
Could not connect to: : 2083
java.net.ConnectException: Connection
refused: connect at
java.net.PlainSocketImpl.socketConnect(Native
Method) at
java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at
java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at
java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at
java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at
java.net.Socket.connect(Socket.java:520)
at
java.net.Socket.connect(Socket.java:470)
at
java.net.Socket.(Socket.java:367)
at
java.net.Socket.(Socket.java:180)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.connect(RemoteTestRunner.java:560)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:377)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
The port number varies.
I found a forum post that told me follow this http://support.microsoft.com/kb/135982
But this did not work.
We are all on Microsoft XP based machines connecting to the internet via an
ISA server/proxy.
I am running Eclipse 3.3.3 and MyEclipse 6.0.1
Any ideas please ?
I have concentrated on junit instead of tomcat as it is much quicker & easier to reproduce.
Yep I had seen the McQueeney link with no luck.
We have done some more digging and interestingly when you run junit from Eclipse, Eclipse decides to go & check for updates, Yes that's right - everytime you run a junit (& I guess tomcat and others).
We removed a colleague's access restrictions to the WWW through the ISA server and low & behold the problem disappeared.
We are still monitoring this to see if it is the solution.
Watch this space.
I have tried looking through the Eclipse set up to see if I can stop it trundling off everytime to the WWW but have not seen a suitable option yet.
Some suggestions...:
Did you look at tomcat logs ?
Do you see in them some ClientAbortException: java.net.SocketException: Broken pipe. ?
It looks like the server thinks the client is closing the connection at times.
And like the client is getting the connection reset by the server (connection reset), and the server is not listening sometimes (connection refused).
If you are testing from behind a firewall/proxy server, you may need to provide TomCat with the firewall/proxy server hostname and port number.
Restarting eclipse should be enough:
Apparently the JUnit runner thread in Eclipse attaches to an Eclipse server thread to run the tests. It would seem the client thread was trying to connect to the wrong port (3393) or that the server thread that had been listening on port 3393 for runtime requests failed.
The solution McQueeney found is here (thank you Archive.org!)
One suggestion I find interesting is:
I had to change the jre that my Eclipse project uses to make sure that JUnit and my project were using the same jre. After a restart of Eclipse the error was gone.
I hope you will find a definitive cause for this.
I had the same problem, when my network driver was broken.
JUnit und Eclipse communicate via ICP (InterProcess Communication), better said: via TCP.
To run it successfully, you have repair your network drivers.
Try to reinstall TCP/IP protocols or turn it back to a system restore point.
Good luck!
So your JUnit only works, if there's a connection to the internet?
Or was it a one time action and now, it works without an internet connection?
Strange world... Are there any hints in a log file?