Closed GoogleCodeExporter closed 8 years ago
1) I don't see anything suspicious in the log snippet. How did you verify the
library used wrong port?
2) Did you start Selenium Server as before the execution or using a keyword in
the test data?
3) If you had exactly `Library SeleniumLibrary ${EMPTY} | ${EMPTY} | 4450`
the syntax is wrong. You should have pipes everywhere or nowhere.
Original comment by pekka.klarck
on 19 Oct 2011 at 9:54
You are correct, I wrote out the syntax for the import wrong. Here is the
actual line we have been using for over a year now.
Library SeleniumLibrary ${EMPTY} ${EMPTY} 4480
How we found this was that when we run our regression suites for the web tests
back to back, every other one was failing with "Connection refused". When I
looked at the selenium_server.log, I found that it was using port 4444 instead
of the port number we were assigning in the Library line. Because we sometimes
run our testsuites stand alone, we have to import the library for each one.
When they are run back to back, the first doesn't free up the port fast enough
for the second to start on the same port. By us changing the port number each
time, there aren't any problems. Only now they SeleniumLibrary seems to be not
accepting the new port number. Even when I changed the testsuite to use the
server_host= it still used port 4444 instead of the port number assigned.
If you would like, I will create a set of suites that will show this and the
startup/shutdown conflict as well.
Original comment by jerry57@gmail.com
on 19 Oct 2011 at 1:01
1) In the log snippet you included the port 4444 is mentioned in instructions
to WebDriver based clients. Was there something else that indicated that wrong
port was used?
2) Having a simple example that demonstrates this problem would be great.
3) Have you considered starting the Selenium Server only once before execution
and closing it afterwards? I've found this approach to be easiest in many
situations. It also reduces the time you need to wait when the server is
running.
Original comment by pekka.klarck
on 19 Oct 2011 at 1:19
Checkout issue #76, it talks about the port conflict and why we use different
ports.
Original comment by jerry57@gmail.com
on 19 Oct 2011 at 1:19
I believe I have finally found where the problem lies and no it is not in the
SeleniumLibrary code. Sorry about the confusion here. One of our new testers
changed a base keyword that loads the library and consequently it wasn't
passing the port info on the Library load. Hence selenium-server always used
the default port.
My apologies to all about this. Please close the issue as non-reproducible.
Thanks,
jer
Original comment by jerry57@gmail.com
on 19 Oct 2011 at 3:51
I understood why you needed to use different ports. What I proposed was
avoiding restarts if possible. Anyway, closing this issue as the problem was in
your test data.
Original comment by pekka.klarck
on 19 Oct 2011 at 6:49
Original issue reported on code.google.com by
jerry57@gmail.com
on 18 Oct 2011 at 11:36