'Xamarin.UITest on physical device address already in use
Since I have problems running my Xamarin.UITest on the iOS Simulator I wanted to try to run it on a physical device. I can run the app from Visual Studio on the device correctly, but running the UITest fails. Unfortunatly I haven't found something about the error online yet.
SetUp : System.Exception : Unable to start portforwarding: ** Message: Probing for device(s)
** Message: Device found: cd70749db00bbf8db8c92d6214a5028ff3b9584d
** (process:35402): CRITICAL **: Unable to claim server port 27753: Error binding to address: Address already in use
I restarted the app and Visual Studio on Mac. The device is activated for UI Automation.
Solution 1:[1]
After restarting the Mac the UITest started.
Solution 2:[2]
Assuming you are using an iPhone
Assure you have the Test Cloud Agent NuGet package installed
Within your iOS project go to AppDelegate.FinishedLaunching() and add ->
#if ENABLE_TEST_CLOUD Xamarin.Calabash.Start(); #endifAlso, add ENABLE_TEST_CLOUD to conditional compilation symbols for iOS project
For reference, check out Microsoft's documentation here .
Solution 3:[3]
I got this error message when trying to execute the Xamarin.UITests on a real iPhone while still having an iPhone Simulator running. After closing the iPhone Simulator the error was not shown any longer.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Stampi |
| Solution 2 | Mr. Mayonnaise |
| Solution 3 | Christopher Stephan |
