"Unable to contact test backend running in app" when trying to run Xamarin UITest locally - xamarin

I am in the early process of learning how to automate Xamarin apps for my company. I started out by just cloning the TailWind Traders app from Microsoft to make sure my system is configured correctly, but I'm running into an issue. After modifying AppManager.cs to use the .app file and attempting to run a single iOS test, I see the app load in the simulator, I get a Mac alert saying "Do you want the application 'DeviceAgent-Runner.app' to accept incoming network transmissions", and then the test fails with this message:
System.Exception : Unable to contact test backend running in app. Check that your app is running and that it is properly configured:
For Xamain.iOS applications, https://learn.microsoft.com/en-us/appcenter/test-cloud/preparing-for-upload/xamarin-ios-uitest
For native iOS applications, https://github.com/calabash/calabash-ios/wiki/Tutorial%3A-How-to-add-Calabash-to-Xcode
Going to that website, I see that it is helping the user configure running tests AppCenter, but I don't want to do that. I simply want to run a test locally on my machine. In trying to fix this, I've uninstalled the Xamarin Test Cloud Agent package and deleted the #if ENABLE_TEST_CLOUD block from AppDelegate.cs. But, it's still happening. How do I run an iOS test locally? Thank you!

If you want to automate uitest using xamarin, it is necessary to add test cloud agent nuget in your xamarin ios project which enable linking to Calabash & install the device agent runner in your mobile. For more detail visit on Microsoft site.
https://learn.microsoft.com/en-us/appcenter/test-cloud/uitest/preparing-for-upload-ios
Whether you upload your test on app enter or run it locally. You have to add test cloud agent nuget in xamarin ios. If you are using native iOS, Calabash linking require to run xamarin uitest.

Related

IPA file unable to run on colleague's phone or untethered from workstation using Meteorjs+ReactJS+Mongodb

I am new to IOS development and have come across an issue and need some help.
I am trying to create an iOS application to target to work on iPhones. I am using MeteorJS, ReactJS with MongoDB for a database.
When I run the ‘meteor run ios’ command I am able to get the Xcode project.
I am also able to load the Xcode project within Xcode and generate the IPA file to demo on my iPhone using ITunes from my MacBook Pro.
When I try to run the application from my iPhone everything works - meaning I was able to connect to the local database (localhost:3001 mongodb). Also, the tests on the application only work when my phone is connected to the Mac.
Now, when I try to export the application and want a colleague to test the iPA file does not work. The IPA file gets installed on the colleague’s phone, however application does not work.
I think I’ve followed the process as required for Adhoc Provisioning profiles however I am not sure whether Im doing this right - because possibly the database is not being packaged with the IPA file?
Could someone please help / Guide?
When running a build produced by meteor run ios, the application on the phone tries to connect to a server running locally on your machine over the networked formed on the physical Lightning cable connection.
While you can configure the iOS client to connect to your machine over your local network, this solution introduces other problems you won't expect. Deploy your application to Galaxy, configure your iOS settings to use the URL on Galaxy, and make a production deployment of your iOS application. Then the iOS application will try to connect to an accessible public Internet URL (your Galaxy deployment), rather than your inaccessible local machine.
See the documentation for details.
meteor run ios-device --mobile-server=http://ip:port
worked for me

Unable to install AppStore version directly to mobile device when using an iOS App Extension

At our company the process we execute normally is:
fix/implement
test ad-hoc version
create AppStore package
test that AppStore package by installing it directly through iTunes.
submit version to AppStore.
The reason why we need to test also the AppStore version is because some payment services wouldn't work if we didn't. So we need a real environment.
Previously to the inclusion of the iOS App Extension (sharing) we could do this process without issues, but now after doing the same process we can't do it anymore.
We can;
test the ad-hoc version by signing the app extension as ad-hoc.
create and submit the app store package.
However we can't install the app store version anymore, the error mentions that there are issues with the signature, more precisely:
(Entitlements found that are not permitted by provisioning profile)
Does anyone have any idea why this could be happening?.
You really shouldn't be able to install the app store version on a physical device and run it.
It can work in certain scenarios (like if you had previously installed development builds on there and there was a valid development build on the device when you try to run the app store build). Maybe the device has the old app provisioning profile (which would not have the app extensions entitlement). The new one that is embedded with the app (and has the appropriate entitlements) is an App Store provisioning profile and is not valid for running directly on the device.
I would make a new build config in your project that is a copy of the Release config, except for only the code signing settings. That would allow you to run a build that will be exactly the production App Store build, except for the code signing settings.

Desktop App Converter/Submit to Windows Store

I have an older application that I've converted using Microsoft's "Desktop App Converter" to create a UWP application. The application appears to convert fine, and I can install and run it on my local machine. Unfortunately, when I try to submit the application to the Windows App Store, I get the following errors:
Package acceptance validation error: We don't allow the capability you've specified: runFullTrust.
Package acceptance validation error: You don't have permissions to specify the following namespaces in the appx manifest file of the package DownloadManager.appx: http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities.
Are there any ideas what is causing this and what the fix is?
I'm running Windows 10 Enterprise Preview Version 1511, Build 14352.1002
According to this article from the official blog, you cannot submit your Centennial apps to the Store just yet. You have to follow the process they mention in their article:
Windows 10 Anniversary Update SDK Now Available! Windows Store Open for Submissions
"Windows Store Open for Submissions; Including Process for Submitting Desktop Bridge Apps:
In addition, we will begin the process of accepting apps using the Desktop Bridge. While we build the pipeline into the Windows Store to publish these apps, our team will work directly with developers to get their converted apps and games into the Windows Store. Contact our team here if you are interested in submitting an app using the Desktop Bridge to the Windows Store."
You can find in this article Preparing your desktop app for conversion to UWP features that should be removed from codebase.
As I see there is one Your app always runs with elevated security privileges.
Check this one ar may be your app contains some another feature from list

Automating iOS 8 app with Appium causes app freeze

We have an app that we run automation tests on with Appium. We can launch the app on the device and simulator through Appium. However, the app hangs and freezes after Appium sends 2-3 tap commands. After the freeze, Appium can not find any other elements on the screen.
We looked into writing a test script using Xcode 6.0.1 Instruments, but when the script is run, the app hangs as well.
The app performs as expected when testing manually. It only hangs when we try to run automation on it either with Appium or with Xcode's Instruments. We are using Appium v1.3.0-beta1, and Xcode 6.0.1.
This seems to be a similar issue to this question, but our test device is already on 8.0.2.
So it turns out that with iOS 8, logging too much data (particularly the case when you're logging API responses) can cause a race condition during Automation. We were able to solve our automation freezing issues by disabling logging from the app.
The solution was discovered thanks to the wonderful analysis by #tbao on this post: https://discuss.appium.io/t/app-freezes-when-automated/1030/8
There is way to restart Appium Server during runtime , which helped us to overcome freezing issue:
Please have a look at my blog for more details:
http://www.qaautomationsimplified.com/android/restarting-appium-server-improve-various-server-freezing-issues-may-improve-execution-time/
Got the same problem when automating web application (Safari) on iOS, solved it by switching from appium 1.15.1 to 1.16.0-beta.3 that is available on mac by executing the install command:
npm install -g appium#beta --unsafe-perm=true --allow-root

Phonegap stuck at detecting iOS SDK environment

i'm trying to create my first app using Phone Gap, so i manage to Build a "generic" app, after installing node.js and phonegap.
So i'm trying to run the following command on the terminal:
phonegap build ios
And it always get stucked on [phonegap] Detecting iOS SDk Environment.
I have, xCode 5, and i do have all the profiles needed to develop, and distribute for iOS, in fact i couple of hours ago, i just send my first app to Itunes Connect, so i think my environment, is fine.
Any ideas? Thanks for the attention!
So, instead of using the command phonegap build ios, I tried phonegap run ios. The program runs, and also a folder was created with the xCode files.
I still dont know what was wrong, but it worked for me.

Resources