2gis / Winium.Mobile

Winium.Mobile is Selenium Remote WebDriver implementation for automated testing of Windows StoreApps and Silverlight apps, tested on emulators (currently only Windows Phone/Mobile apps are supported).
Mozilla Public License 2.0
51 stars 29 forks source link

The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT)) when starting new session #146

Open naix86 opened 8 years ago

naix86 commented 8 years ago

Hi Guys,

I am facing with this issue when I run my sample unit test.

"value": {
    "error": "session not created",
    "stacktrace": "   at Winium.StoreApps.Driver.CommandExecutors.NewSessionExecutor.DoImpl() in d:\\Projects\\windows-universal-app-driver\\Winium\\Winium.StoreApps.Driver\\CommandExecutors\\NewSessionExecutor.cs:line 38\r\n   at Winium.StoreApps.Driver.CommandExecutors.CommandExecutorBase.Do() in d:\\Projects\\windows-universal-app-driver\\Winium\\Winium.StoreApps.Driver\\CommandExecutors\\CommandExecutorBase.cs:line 42",
    "message": "The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))"
  }
}

Any idea why this happened?

NickAb commented 8 years ago

Can you provide logs written by Winium.StoreApps.Driver.exe? It is recommended to run Winium.StoreApps.Driver.exe with --verbose option, so that you get more logs.

Without logs it is hard to diagnose it but this is unusual exception. Try restarting emulator that you run tests on.

naix86 commented 8 years ago

Hi Nick,

I got it working finally.

Btw, how can i run two [Test] in a single CS script?

When I try to run two [Test], one of them will just have an error saying "InvalidOperationException: The application is already installed, or update or uninstall is running" etc.

NickAb commented 8 years ago

I will need some code sample to tell if there is any problem. But in general you can have a single .cs file with single test class that have a bunch of test methods in it, see https://github.com/2gis/Winium.StoreApps/blob/master/Winium/TestApp.Test/Samples/TestSamples.cs for example.

NickAb commented 8 years ago

@naix86 have my answer resolved you question? If so i would like to close the issue.

naix86 commented 8 years ago

HI Nick,

I can't get winium to run everytime. average to be like 1 out 10 success. I keep getting the same thing

"message": "The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))"

Please help

NickAb commented 8 years ago

Could you please try running tests and emulators on another machine? This problem might be related to hardware or software setup.

NickAb commented 7 years ago

@naix86 does the issues persist on different hardware?