Migrate your XCUI tests from Microsoft App Center
Use our XCUI integration on App Automate to test on 3000+ devices on our real device cloud.
This guide maps the Microsoft App Center XCUITest workflow to its BrowserStack App Automate equivalent, so you can move your existing test runs across with minimal changes. The migration comes down to three REST API calls: upload the app, upload the test suite, and trigger the build.
- This would apply in case you are using the CLI or App Center Task for Azure Pipelines to trigger XCUI tests on App Center.
- You would need to first sign up for a BrowserStack account
- Once you have signed up, you need to purchase a plan on BrowserStack. You can see all the plans on the App Automate pricing page
- You can use App Automate’s XCUI APIs to migrate from the App Center to BrowserStack. It requires 3 API calls with the relevant params to run all the tests on BrowserStack.
- You can read more about App Automate’s XCUI APIs in the XCUI getting started guide
- The first of the 3 API calls mentioned above would be to upload the App
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/xcuitest/v2/app" \
-F "file=@/path/to/app/file/Application.ipa"
- The second of the 3 API calls mentioned above would be to upload the test suite.
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/xcuitest/v2/test-suite" \
-F "file=@/path/to/app/file/Application-debug-test.zip"
-
The last of the 3 API calls mentioned above would be to upload the finally trigger the test with the relevant params. You can find the documentation in the Execute a Build API reference.
- You would probably be using a CLI command like this -
appcenter test run xcuitest \ --app "${APP}" \ --devices "${1}" \ --build-dir "${WORKSPACE}" \ --test-series "${SERIES}" \ --token "${APPCENTER_TOKEN}" \ --disable-telemetry - This CLI command has multiple parameters like
appanddevices - For each one of these CLI parameters you can find an equivalent param for the XCUI API, you can find documentation on each param in the Execute a Build API reference
- All you would need to do would be to convert each one of the CLI params to API params and then trigger the tests on BrowserStack using the Execute Build API.
- The final API call would look something like this. Once this API call is done, BrowserStack will take care of running the XCUI Tests.
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/xcuitest/v2/build" \
-d '{"app": "bs://9c6dcb5649a8280ca800075bfd8f151115bba6b3", "testSuite": "bs://89c874f21852ba57957a3fdc33f47514288c4ba1","project" : "XCUI_Test", "devices": ["iPhone 11-13"]}' \
-H "Content-Type: application/json"
- XCUI Support on BrowserStack is also available in case you are using XCTest Plans too. You can refer to the XCTest plans getting started guide
Further troubleshooting
- There are certain Core Concepts in App Center defined in the App Center core concepts documentation , for each one of these Core Concepts in App Center, there is one in BrowserStack. We are listing them down below
- The core concept of ‘Device Configuration’ in App Center is a combination of device model and operating system version. You can select the same device and OS version you want on BrowserStack too. You can read more in the specify devices guide.
- Similar to how there are Device Tiers in App Center , there are Device Tiers in BrowserStack too , you can read more about them on the Device Tiers page.
- The core concept of ‘Device Concurrency’ in App Center will map to the concept of Parallels in App Automate.
- The core concept of ‘Test Run’ and ‘Test Report’ would equate to an XCUI Session and its Reports on BrowserStack. You can see your XCUI Sessions on either the test results dashboard or you can use our session details API
- The core concept of ‘Test Series’ which is an arbitrary system for organizing your test runs, maps directly to the ‘Build Name’ in BrowserStack’s API params. Also BrowserStack provides multiple other ways of organizing your tests, you can read more in the organize tests guide.
- The screenshots for XCUI tests are available with BrowserStack via the result bundle for XCUI you can read more in the get result bundle API reference. Also a video is available for all your XCUI tests on BrowserStack.
We're sorry to hear that. Please share your feedback so we can do better
Contact our Support team for immediate help while we work on improving our docs.
We're continuously improving our docs. We'd love to know what you liked
We're sorry to hear that. Please share your feedback so we can do better
Contact our Support team for immediate help while we work on improving our docs.
We're continuously improving our docs. We'd love to know what you liked
Thank you for your valuable feedback!