Closed jalona closed 8 years ago
Hello, Ruslan!
The BAD_HUB_JSON error tells that Grid Router got a response from underlying server not in json format, possibly in plain html or plain text. Is there Selenium Hub in front of winium? If so, could you please see hub logs and provide us with the real error. Also, please describe the environment you are using (selenium version, winium, etc) so we can try to reproduce the issue.
Alexander Andryashin.
2016-05-05 9:20 GMT+03:00 Ruslan Shevchenko notifications@github.com:
In grid console
2016-05-05 08:11:33,024 [9602862-13] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [firefox] [http://10.6.33.88:4444] [1] 2016-05-05 08:11:37,980 [9602862-13] INFO RouteServlet - [SESSION_CREATED] [usertest] [10.6.33.88] [firefox] [http://10.6.33.88:4444] [0ec52d59-fc3b-492c-9c82-e2031d40d3c1] [1] 2016-05-05 08:11:41,718 [9602862-16] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [winium] [http://10.6.2.72:9999] [1] 2016-05-05 08:11:41,726 [9602862-16] ERROR RouteServlet - [BAD_HUB_JSON] [] [usertest] [10.6.33.88] - winium 2016-05-05 08:11:41,726 [9602862-16] ERROR RouteServlet - [SESSION_NOT_CREATED] [usertest] [10.6.33.88] [winium] 2016-05-05 08:11:45,561 [9602862-11] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [winium] [http://10.6.2.72:9999] [1] 2016-05-05 08:11:45,566 [9602862-11] ERROR RouteServlet - [BAD_HUB_JSON] [] [usertest] [10.6.33.88] - winium 2016-05-05 08:11:45,566 [9602862-11] ERROR RouteServlet - [SESSION_NOT_CREATED] [usertest] [10.6.33.88] [winium] 2016-05-05 08:11:48,239 [9602862-17] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [winium] [http://10.6.2.72:9999] [1] 2016-05-05 08:11:48,248 [9602862-17] ERROR RouteServlet - [BAD_HUB_JSON] [] [usertest] [10.6.33.88] - winium 2016-05-05 08:11:48,248 [9602862-17] ERROR RouteServlet - [SESSION_NOT_CREATED] [usertest] [10.6.33.88] [winium] 2016-05-05 08:11:51,145 [9602862-10] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [winium] [http://10.6.2.72:9999] [1] 2016-05-05 08:11:51,150 [9602862-10] ERROR RouteServlet - [BAD_HUB_JSON] [] [usertest] [10.6.33.88] - winium 2016-05-05 08:11:51,151 [9602862-10] ERROR RouteServlet - [SESSION_NOT_CREATED] [usertest] [10.6.33.88] [winium] 2016-05-05 08:11:51,790 [9602862-16] INFO RouteServlet - [SESSION_ATTEMPTED] [usertest] [10.6.33.88] [winium] [http://10.6.2.72:9999] [1] 2016-05-05 08:11:51,795 [9602862-16] ERROR RouteServlet - [BAD_HUB_JSON] [] [usertest] [10.6.33.88] - winium 2016-05-05 08:11:51,795 [9602862-16] ERROR RouteServlet - [SESSION_NOT_CREATED] [usertest] [10.6.33.88] [winium] 2016-05-05 08:11:51,863 [9602862-13] INFO ProxyServlet - [SESSION_DELETED] [10.6.33.88] [http://10.6.33.88:4444] [0ec52d59-fc3b-492c-9c82-e2031d40d3c1]
Init driver for WINIUM:
DesiredCapabilities cap = new DesiredCapabilities(); cap.setCapability("app", "C:-test*\*.exe"); cap.setCapability("launchDelay", 30000); cap.setBrowserName("winium");
driver = new RemoteWebDriver(new URL("http://usertest:usertest@example.domen.ru:4444/wd/hub"), cap);
Init driver for Firefox:
DesiredCapabilities cap = new DesiredCapabilities(); cap.setBrowserName("firefox");
driver = new RemoteWebDriver(new URL("http://usertest:usertest@example.domen.ru:4444/wd/hub"), cap);
— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/seleniumkit/gridrouter/issues/24
Привет, Саша. Я не использую selenium hub.
cucumber 1.2.4
selenium 2.52.0
winium 1.5.0
Если указывать winium драйвер напрямую, в обход gridrouter (взятый с ppa:yandex-qatools/gridrouter), то проблем не возникает.
Starting Windows Desktop Driver on port 9999
12:27:44 [DEBUG] Waiting for a connection...
12:28:32 [DEBUG] ACCEPTED REQUEST POST /session HTTP/1.1
12:28:33 [INFO] COMMAND newSession
{
"desiredCapabilities": {
"app": "C:\\***-test\\***\\****.exe",
"launchDelay": 30000,
"browserName": "winium"
}
}
12:28:33 [DEBUG] Current keyboard simulator: BasedOnInputSimulatorLib
12:29:03 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"app":"C:\\homer-test\\HOM
ER.NET\\HomeR.exe","args":"","debugConnectToRunningApp":false,"innerPort":9998,"
keyboardSimulator":1,"launchDelay":30000}}
12:29:03 [DEBUG] Client closed
12:29:03 [DEBUG] Waiting for a connection...
12:30:06 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:06 [INFO] COMMAND findElement
{
"using": "id",
"value": "tbUsrName",
"SESSIONID": "AwesomeSession"
}
12:30:07 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"4129514-1"}}
12:30:07 [DEBUG] Client closed
12:30:07 [DEBUG] Waiting for a connection...
12:30:07 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/4129514-1/
attribute/value HTTP/1.1
12:30:07 [INFO] COMMAND getElementAttribute
{
"SESSIONID": "AwesomeSession",
"ID": "4129514-1",
"NAME": "value"
}
12:30:07 [ERROR] Property 'value' is not UI Automation Property
12:30:07 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:07 [DEBUG] Client closed
12:30:07 [DEBUG] Waiting for a connection...
12:30:07 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/4129514-1
/value HTTP/1.1
12:30:07 [INFO] COMMAND sendKeysToElement
{
"id": "4129514-1",
"value": [
"drakula"
],
"SESSIONID": "AwesomeSession",
"ID": "4129514-1"
}
12:30:07 [INFO] Click on 'type: ControlType.Edit, uid: tbUsrName, name: HomeCred
it a.s.' element at (778, 342) ClickablePoint
12:30:07 [INFO] Press key combo 'CONTROL + VK_A'
12:30:07 [INFO] Key press 'BACK'
12:30:08 [INFO] Send text 'drakula'
12:30:08 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:08 [DEBUG] Client closed
12:30:08 [DEBUG] Waiting for a connection...
12:30:08 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/4129514-1/
attribute/value HTTP/1.1
12:30:08 [INFO] COMMAND getElementAttribute
{
"SESSIONID": "AwesomeSession",
"ID": "4129514-1",
"NAME": "value"
}
12:30:08 [ERROR] Property 'value' is not UI Automation Property
12:30:08 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:08 [DEBUG] Client closed
12:30:08 [DEBUG] Waiting for a connection...
12:30:08 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:08 [INFO] COMMAND findElement
{
"using": "id",
"value": "tbPassword",
"SESSIONID": "AwesomeSession"
}
12:30:08 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"6226514-2"}}
12:30:08 [DEBUG] Client closed
12:30:08 [DEBUG] Waiting for a connection...
12:30:08 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/6226514-2/
attribute/value HTTP/1.1
12:30:08 [INFO] COMMAND getElementAttribute
{
"SESSIONID": "AwesomeSession",
"ID": "6226514-2",
"NAME": "value"
}
12:30:08 [ERROR] Property 'value' is not UI Automation Property
12:30:08 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:08 [DEBUG] Client closed
12:30:08 [DEBUG] Waiting for a connection...
12:30:08 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/6226514-2
/value HTTP/1.1
12:30:08 [INFO] COMMAND sendKeysToElement
{
"id": "6226514-2",
"value": [
"drakula"
],
"SESSIONID": "AwesomeSession",
"ID": "6226514-2"
}
12:30:09 [INFO] Click on 'type: ControlType.Edit, uid: tbPassword, name: Имя:' e
lement at (778, 368) ClickablePoint
12:30:09 [INFO] Press key combo 'CONTROL + VK_A'
12:30:09 [INFO] Key press 'BACK'
12:30:10 [INFO] Send text 'drakula'
12:30:10 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:10 [DEBUG] Client closed
12:30:10 [DEBUG] Waiting for a connection...
12:30:10 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/6226514-2/
attribute/value HTTP/1.1
12:30:10 [INFO] COMMAND getElementAttribute
{
"SESSIONID": "AwesomeSession",
"ID": "6226514-2",
"NAME": "value"
}
12:30:10 [ERROR] Property 'value' is not UI Automation Property
12:30:10 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:10 [DEBUG] Client closed
12:30:10 [DEBUG] Waiting for a connection...
12:30:10 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:10 [INFO] COMMAND findElement
{
"using": "id",
"value": "DropDown",
"SESSIONID": "AwesomeSession"
}
12:30:10 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"-23333725-3"}}
12:30:10 [DEBUG] Client closed
12:30:10 [DEBUG] Waiting for a connection...
12:30:10 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/-23333725
-3/click HTTP/1.1
12:30:10 [INFO] COMMAND clickElement
{
"id": "-23333725-3",
"SESSIONID": "AwesomeSession",
"ID": "-23333725-3"
}
12:30:11 [INFO] Click on 'type: ControlType.Button, uid: DropDown, name: Кнопка
раскрытия списка' element at (834, 403) ClickablePoint
12:30:11 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:11 [DEBUG] Client closed
12:30:11 [DEBUG] Waiting for a connection...
12:30:11 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:11 [INFO] COMMAND findElement
{
"using": "name",
"value": "RU61B1",
"SESSIONID": "AwesomeSession"
}
12:30:11 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"23333727-4"}}
12:30:11 [DEBUG] Client closed
12:30:11 [DEBUG] Waiting for a connection...
12:30:11 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/23333727-
4/click HTTP/1.1
12:30:11 [INFO] COMMAND clickElement
{
"id": "23333727-4",
"SESSIONID": "AwesomeSession",
"ID": "23333727-4"
}
12:30:12 [INFO] Click on 'type: ControlType.ListItem, name: RU61B1' element at (
786, 460) ClickablePoint
12:30:12 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:12 [DEBUG] Client closed
12:30:12 [DEBUG] Waiting for a connection...
12:30:12 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:12 [INFO] COMMAND findElement
{
"using": "id",
"value": "btOK",
"SESSIONID": "AwesomeSession"
}
12:30:12 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"3605262-5"}}
12:30:12 [DEBUG] Client closed
12:30:12 [DEBUG] Waiting for a connection...
12:30:12 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/3605262-5
/click HTTP/1.1
12:30:12 [INFO] COMMAND clickElement
{
"id": "3605262-5",
"SESSIONID": "AwesomeSession",
"ID": "3605262-5"
}
12:30:13 [INFO] Click on 'type: ControlType.Button, uid: btOK, name: OK' element
at (618, 444) ClickablePoint
12:30:15 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:15 [DEBUG] Client closed
12:30:15 [DEBUG] Waiting for a connection...
12:30:46 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:46 [INFO] COMMAND findElement
{
"using": "name",
"value": "Модули",
"SESSIONID": "AwesomeSession"
}
12:30:47 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"36440285-6"}}
12:30:47 [DEBUG] Client closed
12:30:47 [DEBUG] Waiting for a connection...
12:30:47 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/36440285-
6/click HTTP/1.1
12:30:47 [INFO] COMMAND clickElement
{
"id": "36440285-6",
"SESSIONID": "AwesomeSession",
"ID": "36440285-6"
}
12:30:47 [INFO] Click on 'type: ControlType.MenuItem, name: Модули' element at (
353, 41) ClickablePoint
12:30:47 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:47 [DEBUG] Client closed
12:30:47 [DEBUG] Waiting for a connection...
12:30:47 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:47 [INFO] COMMAND findElement
{
"using": "name",
"value": "Редактирование сведений о лице",
"SESSIONID": "AwesomeSession"
}
12:30:49 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"72880547-7"}}
12:30:49 [DEBUG] Client closed
12:30:49 [DEBUG] Waiting for a connection...
12:30:49 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element/72880547-
7/click HTTP/1.1
12:30:49 [INFO] COMMAND clickElement
{
"id": "72880547-7",
"SESSIONID": "AwesomeSession",
"ID": "72880547-7"
}
12:30:57 [DEBUG] Element 'type: ControlType.MenuItem, name: Редактирование сведе
ний о лице' not have ClickablePoint
12:30:57 [INFO] Click on 'type: ControlType.MenuItem, name: Редактирование сведе
ний о лице' element at (490,5, 613) BoundingRectangle center
12:30:57 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:30:57 [DEBUG] Client closed
12:30:57 [DEBUG] Waiting for a connection...
12:30:57 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
12:30:57 [INFO] COMMAND findElement
{
"using": "id",
"value": "StatusBar.Pane2",
"SESSIONID": "AwesomeSession"
}
12:30:58 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"28051782-8"}}
12:30:58 [DEBUG] Client closed
12:30:58 [DEBUG] Waiting for a connection...
12:30:58 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/28051782-8
/text HTTP/1.1
12:30:58 [INFO] COMMAND getElementText
{
"SESSIONID": "AwesomeSession",
"ID": "28051782-8"
}
12:30:58 [DEBUG] Element 'type: ControlType.Edit, uid: StatusBar.Pane2, name: Мо
дуль: HCI.EditPerson 161.1.1' not support TextPattern
12:30:58 [INFO] Element 'type: ControlType.Edit, uid: StatusBar.Pane2, name: Мод
уль: HCI.EditPerson 161.1.1' return text with use ValuePattern
12:30:58 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":"Модуль: HCI.EditPerson 161
.1.1"}
12:30:58 [DEBUG] Client closed
12:30:58 [DEBUG] Waiting for a connection...
12:32:13 [DEBUG] ACCEPTED REQUEST DELETE /session/AwesomeSession/window HTTP/1.1
12:32:13 [INFO] COMMAND close
{
"SESSIONID": "AwesomeSession"
}
12:32:23 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:32:23 [DEBUG] Client closed
12:32:23 [DEBUG] Waiting for a connection...
12:32:23 [DEBUG] ACCEPTED REQUEST DELETE /session/AwesomeSession HTTP/1.1
12:32:23 [INFO] COMMAND quit
{
"SESSIONID": "AwesomeSession"
}
12:32:23 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":null}
12:32:23 [DEBUG] Client closed
12:32:23 [DEBUG] Waiting for a connection...
Вот тест в проекте, который воспроизводит ошибку
@Test(expected = WebDriverException.class)
public void testWINIUM() {
DesiredCapabilities desiredCapabilities = new DesiredCapabilities();
desiredCapabilities.setCapability("browserName", "winium");
desiredCapabilities.setCapability("app", "C:\\***-test\\***\\****.exe");
desiredCapabilities.setCapability("launchDelay", 30000);
new RemoteWebDriver(GridRouterRule.hubUrl(BASE_URL_WITH_AUTH), desiredCapabilities);
}
user1.xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:browsers xmlns:ns2="urn:config.gridrouter.qatools.ru">
<browser name="winium" defaultVersion="1.5">
<version number="1.5">
<region name="first">
<host name="10.6.2.72" port="9999" count="1"/>
</region>
</version>
</browser>
</ns2:browsers>
2016-05-05 12:47:33,273 INFO ru.qatools.gridrouter.RouteServlet - [SESSION_ATTEMPTED] [user1] [127.0.0.1] [winium] [http://10.6.2.72:9999] [1]
2016-05-05 12:47:33,415 ERROR ru.qatools.gridrouter.RouteServlet - [BAD_HUB_JSON] [] [user1] [127.0.0.1] - winium
2016-05-05 12:47:33,415 ERROR ru.qatools.gridrouter.RouteServlet - [SESSION_NOT_CREATED] [user1] [127.0.0.1] [winium]
it seems for me that at the beginning Winium didn't understand session request
09:27:06 [WARN] Unknown command recived: http://localhost:9999/wd/hub/session
Then, probably, it responds something unexpected to GridRouter.
My guess - GridRouter might break capability
cap.setCapability("app", "C:-test*\*.exe");
when proxying request to the Winium and request becomes invalid
Another wild guess is that you have some problems with quota. Can you show it?
@levsha932
<qa:browsers xmlns:qa="urn:config.gridrouter.qatools.ru">
<browser name="firefox" defaultVersion="44.0.2">
<version number="44.0.2">
<region name="us-west">
<host name="10.6.33.88" port="4444" count="5"/>
</region>
<region name="us-east">
<host name="10.6.61.34" port="4444" count="5"/>
</region>
</version>
</browser>
<browser name="winium" defaultVersion="1.5.0">
<version number="1.5.0">
<region name="us-west">
<host name="10.6.2.72" port="9999" count="1"/>
</region>
</version>
</browser>
</qa:browsers>
Could you try to go directly to winium but provide also capability version=1.5.0 This way you can check how winium reacts on this capability (which we anyway add to your capabilities when request goes through GridRouter)
@levsha932
...
DesiredCapabilities cap = new DesiredCapabilities();
cap.setCapability("app", "C:\\***-test\\***\\****.exe");
cap.setCapability("launchDelay", 30000);
cap.setBrowserName("winium");
cap.setCapability("version", "1.5.0");
driver = new RemoteWebDriver(new URL("http://10.6.2.72:9999"), cap);
...
Starting Windows Desktop Driver on port 9999
14:23:46 [DEBUG] Waiting for a connection...
14:27:30 [DEBUG] ACCEPTED REQUEST POST /session HTTP/1.1
14:27:30 [INFO] COMMAND newSession
{
"desiredCapabilities": {
"app": "C:\\***-test\\***\\****.exe",
"launchDelay": 30000,
"browserName": "winium",
"version": "1.5.0"
}
}
14:27:31 [DEBUG] Current keyboard simulator: BasedOnInputSimulatorLib
14:28:02 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"app":"C:\\***-test\\***\\****.exe","args":"","debugConnectToRunningApp":false,"innerPort":9998,"
keyboardSimulator":1,"launchDelay":30000}}
14:28:02 [DEBUG] Client closed
14:28:02 [DEBUG] Waiting for a connection...
14:29:05 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1
14:29:06 [INFO] COMMAND findElement
{
"using": "id",
"value": "tbUsrName",
"SESSIONID": "AwesomeSession"
}
14:29:07 [DEBUG] RESPONSE:
OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"4129106-1"}}
14:29:07 [DEBUG] Client closed
14:29:07 [DEBUG] Waiting for a connection...
14:29:07 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/4129106-1/
...
Ruslan,
I am trying to reproduce the issue, and when I tried to start Winium on Windows virtual machine I got this error:
$ ./Winium.Desktop.Driver.exe
Unhandled Exception: System.ArgumentException: LayoutRenderer cannot be found: 'longdate' at NLog.Config.Factory`2.CreateInstance(String name) at NLog.Layouts.LayoutParser.ParseLayoutRenderer(ConfigurationItemFactory configurationItemFactory, SimpleStringReader sr) at NLog.Layouts.LayoutParser.CompileLayout(ConfigurationItemFactory configurationItemFactory, SimpleStringReader sr, Boolean isNested, String& text) at NLog.Layouts.SimpleLayout.set_Text(String value) at NLog.Targets.TargetWithLayout..ctor() at Winium.Desktop.Driver.Logger.TargetConsole(Boolean verbose) at Winium.Desktop.Driver.Program.Main(String[] args)
Could you please help me?
2016-05-05 14:34 GMT+03:00 Ruslan Shevchenko notifications@github.com:
@levsha932 https://github.com/levsha932
... DesiredCapabilities cap = new DesiredCapabilities(); cap.setCapability("app", "C:*_-test*_****.exe"); cap.setCapability("launchDelay", 30000); cap.setBrowserName("winium"); cap.setCapability("version", "1.5.0");
driver = new RemoteWebDriver(new URL("http://10.6.2.72:9999"), cap); ...
Starting Windows Desktop Driver on port 9999
14:23:46 [DEBUG] Waiting for a connection... 14:27:30 [DEBUG] ACCEPTED REQUEST POST /session HTTP/1.1 14:27:30 [INFO] COMMAND newSession { "desiredCapabilities": { "app": "C:*_-test****.exe", "launchDelay": 30000, "browserName": "winium", "version": "1.5.0" } } 14:27:31 [DEBUG] Current keyboard simulator: BasedOnInputSimulatorLib 14:28:02 [DEBUG] RESPONSE: OK: {"sessionId":"AwesomeSession","status":0,"value":{"app":"C:*_-test****.exe","args":"","debugConnectToRunningApp":false,"innerPort":9998," keyboardSimulator":1,"launchDelay":30000}} 14:28:02 [DEBUG] Client closed
14:28:02 [DEBUG] Waiting for a connection... 14:29:05 [DEBUG] ACCEPTED REQUEST POST /session/AwesomeSession/element HTTP/1.1 14:29:06 [INFO] COMMAND findElement { "using": "id", "value": "tbUsrName", "SESSIONID": "AwesomeSession" } 14:29:07 [DEBUG] RESPONSE: OK: {"sessionId":"AwesomeSession","status":0,"value":{"ELEMENT":"4129106-1"}} 14:29:07 [DEBUG] Client closed
14:29:07 [DEBUG] Waiting for a connection... 14:29:07 [DEBUG] ACCEPTED REQUEST GET /session/AwesomeSession/element/4129106-1/
...
— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/seleniumkit/gridrouter/issues/24#issuecomment-217130350
@aandryashin, need install dotNetFramework 4.5
for debug driver:
start Winium.Desktop.Driver.exe --verbose
You need to start Winium driver with --url-base=wd/hub
, then it will start recognising wd/hub/status
command. If no prefix is setup, then it treats wd/hub
as part of command name.
Note that it might be not enough to run Winium.Desktop with selenium grid as such usage was not tested for Desktop driver.
Thank you, Ruslan, it works!
Could you please tell me which app I can setup in capabilities, only for testing reason, for example notepad.exe or other?
2016-05-05 15:05 GMT+03:00 Ruslan Shevchenko notifications@github.com:
@aandryashin https://github.com/aandryashin, need install NetFramework 4.5
— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/seleniumkit/gridrouter/issues/24#issuecomment-217136998
Unfortunately, I could not reproduce the issue. I have installed winium and get it running on port 9999, then I have created "C:\one test" (with space bar) directory and copied calc.exe there. Then created quota:
Problem accessing /wd/hub/session. Reason:[\n]" 2016-05-05 17:51:09,223 DEBUG wire - http-outgoing-0 << "
Unauthorized
It's true. Need add --url-base=wd/hub
in parametrs winium start
This solved my a problem.
Good work. Thanks to all who helped.
@jalona Can you please help me setting up the Winium server as node for selenium grid. I tried by executing below command but this isnt working
start Winium.Desktop.Driver.exe --nodeConfig=C:\workspace\java\nodeconfig.json --verbose --url-base=wd/hub
Attached is the JSON file used nodeconfig.txt
In grid console
In Winium console
Init driver for WINIUM:
Init driver for Firefox: