Selenium RC: Server Exception

2 views
Skip to first unread message

Gavin Brewer

unread,
Dec 23, 2008, 4:40:15 AM12/23/08
to selenium-users...@googlegroups.com
NewTest is compiled and run, and we get the following result:

{font:style=color: #3366ff;}C:\selenium_test>*java junit.textui.TestRunner NewTest* \\ .E \\ Time: 21.765 \\ There was 1 error: \\ 1) testNew(NewTest)com.thoughtworks.selenium.SeleniumException: ERROR Server Exception: sessionId should not be null; has this session been started yet? \\         at com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandProcessor.java:73) \\         at com.thoughtworks.selenium.DefaultSelenium.setContext(DefaultSelenium.java:574) \\         at com.thoughtworks.selenium.SeleneseTestCase.setUp(SeleneseTestCase.java:126) \\         at NewTest.setUp(NewTest.java:8) \\         at com.thoughtworks.selenium.SeleneseTestCase.runBare(SeleneseTestCase.java:71){font}

{font:style=color: #3366ff;}FAILURES!!! \\ Tests run: 1,  Failures: 0,  Errors:{font}

Anyone know what's going on here?

Thanks,
              Gavin.

Gavin Brewer

unread,
Dec 23, 2008, 4:51:28 AM12/23/08
to selenium-users...@googlegroups.com
The Selenium Server is running, and the following line is displayed in the console window:

{font:style=color: #3366ff;}09:47:06.574 INFO - Got result: ERROR Server Exception: sessionId should not be \\ null; has this session been started yet? on session null{font}

Gavin Brewer

unread,
Dec 23, 2008, 9:37:30 AM12/23/08
to selenium-users...@googlegroups.com
BTW Here is my code:

{font:style=color: #993366;}import com.thoughtworks.selenium.*; \\ import java.util.regex.Pattern;{font}

{font:style=color: #993366;}public class NewTest extends SeleneseTestCase { \\     public void setUp() throws Exception { \\         setUp("http://www.google.com/", "*chrome"); \\     } \\     public void testNew() throws Exception { \\         selenium.open("/ig?hl=en"); \\         selenium.type("q", "hello world"); \\         selenium.click("btnG"); \\         selenium.waitForPageToLoad("30000"); \\         verifyEquals("hello world - Google Search", selenium.getTitle()); \\     } \\ }{font}

It appears that running this script is successful if I use *iexplore instead of *chrome.

Cheers,
               Gavin.

Amit

unread,
Dec 23, 2008, 12:20:05 PM12/23/08
to selenium-users...@googlegroups.com
Run the SRC server with -multiWindow option.

Thanks
-Amit

Reply all
Reply to author
Forward
0 new messages