When I use the following Test Java source to try google test with selenium RC, it reported the following errors, after change the mode to "piiexplore" it still showed the same error, any one can help me? Thanks in advance!
==== Test Java source ====
import com.thoughtworks.selenium.*;
import junit.framework.*;
public class GoogleTest extends TestCase {
private Selenium sel;
public void setUp() {
sel = new DefaultSelenium("localhost", 7788, "*iexplore",
"
http://www.google.com");
sel.start();
}
public void testGoogle() {
sel.open("
http://www.google.com");
sel.type("q", "hello world");
sel.click("btnG");
sel.waitForPageToLoad("5000");
assertEquals("hello world - Google 搜索", sel.getTitle());
}
public void tearDown() {
sel.stop();
}
}
==== Error reported =====
D:\OpenSource\selenium-remote-control-0.9.0\server>java -jar selenium-server.jar -proxyInjectionMode -port 7788 -Dhttp.proxyHost={code:html}<PROXY_HOST> -Dhttp.proxyPort=<PROXY_PORT> -Dhttp.proxyUser=<PROXY_USER> -Dhttp.proxyPassword=<PROXY_PASSWORD>
Setting system property http.proxyHost to <PROXY_HOST>
Setting system property http.proxyPort to <PROXY_PORT>
Setting system property http.proxyUser to <PROXY_USER>
Setting system property http.proxyPassword to <PROXY_PASSWORD>
application/xhtml+xml
The selenium server will execute in proxyInjection mode.
2007-4-16 9:19:14 org.mortbay.http.HttpServer doStart
信息: Version Jetty/0.9.0
2007-4-16 9:19:14 org.mortbay.util.Container start
信息: Started HttpContext[/,/]
2007-4-16 9:19:14 org.mortbay.util.Container start
信息: Started HttpContext[/selenium-server,/selenium-server]
2007-4-16 9:19:14 org.mortbay.util.Container start
信息: Started HttpContext[/selenium-server/driver,/selenium-server/driver]
2007-4-16 9:19:14 org.mortbay.http.SocketListener start
信息: Started SocketListener on
0.0.0.0:7788
2007-4-16 9:19:14 org.mortbay.util.Container start
信息: Started org.mortbay.jetty.Server@1d58aae
2007-4-16 9:19:20 org.mortbay.util.FileResource <clinit>{code}
信息: Checking Resource aliases
GET: cmd=getNewBrowserSession&1=*iexplore&2=http%3A%2F%
2Fwww.google.com
WARNING: running in proxy injection mode, but you used a *iexplore browser string; this is almost surely inappropriate, so I'm changing it to *piiexplore...
Backing up registry settings...
2007-4-16 9:19:21 org.mortbay.http.HttpConnection exception
警告: GET /selenium-server/driver/?cmd=getNewBrowserSession&1=*iexplore&2=http%3A%2F%
2Fwww.google.com HTTP/1.1
org.openqa.selenium.server.browserlaunchers.WindowsUtils$WindowsRegistryException: Problem while managaging the registry, OS Version '5.1', regVersion1 = false
at org.openqa.selenium.server.browserlaunchers.WindowsUtils.readIntRegistryValue(WindowsUtils.java:433)
at org.openqa.selenium.server.browserlaunchers.WindowsUtils.readBooleanRegistryValue(WindowsUtils.java:451)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher$RegKeyBackup.copyBoolean(InternetExplorerCustomProxyLauncher.java:348)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher$RegKeyBackup.copy(InternetExplorerCustomProxyLauncher.java:333)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher$RegKeyBackup.backup(InternetExplorerCustomProxyLauncher.java:308)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher$RegKeyBackup.access$000(InternetExplorerCustomProxyLauncher.java:287)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher.backupRegistrySettings(InternetExplorerCustomProxyLauncher.java:218)
at org.openqa.selenium.server.browserlaunchers.InternetExplorerCustomProxyLauncher.launch(InternetExplorerCustomProxyLauncher.java:156)
at org.openqa.selenium.server.browserlaunchers.AbstractBrowserLauncher.launchRemoteSession(AbstractBrowserLauncher.java:24)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.getNewBrowserSession(SeleniumDriverResourceHandler.java:470)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.doCommand(SeleniumDriverResourceHandler.java:316)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.handleCommandRequest(SeleniumDriverResourceHandler.java:296)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.handle(SeleniumDriverResourceHandler.java:129)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1530)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1482)
at org.mortbay.http.HttpServer.service(HttpServer.java:909)
at org.mortbay.http.HttpConnection.service(HttpConnection.java:816)
at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:982)
at org.mortbay.http.HttpConnection.handle(HttpConnection.java:833)
at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244)
at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:357)
at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)
Caused by: java.lang.RuntimeException: Output didn't look right: ! REG.EXE VERSION 3.0
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings
ProxyOverride REG_SZ *.
oocl.com;*.
corp.oocl.com;*.
dgsmart.com;*.
depotsmart.com;*.
epeoplesmart.com;*.
oocllogistics.com;*.
esi-intermodal.com;*.
oocl-log.com.cn;*.
portnet.co
m.sg;146.222.*.*;*.
operationsmart.com;*.
ooilgroup.com;*.
schedulingsmart.com;*.
ooclpilot.com;{code:html}<local>
at org.openqa.selenium.server.browserlaunchers.WindowsUtils$WindowsRegistryException.<init>{code}(WindowsUtils.java:643)
... 22 more
GET: cmd=open&1=http%3A%2F%
2Fwww.google.com