Features

Set localization options

With TestingBot you can run Android Espresso tests on a localized version of your Android app.
You can configure the language, locale and timezone of the remote device before running an Android Espresso test.

Setting Language for Android Espresso Tests

You can test a localized version of your app with Android Espresso, by changing the language of the application under test.
You will need to specify a language option with the ISO code of the language you want to use.

Copy code
curl -u api_key:api_secret \
-X POST "https://api.testingbot.com/v1/app-automate/espresso/:id/run" \
-d '{ "espressoOptions": { "language": "fr" }, "capabilities":[{"platform":"ANDROID", "version":12, "deviceName":"Pixel 6", "platformName":"Android"}]}' \
-H "Content-Type: application/json"

Use an ISO 639-1 language code to set the language of your app.
Your app needs to be compiled with support for this language to notice a change.

Set a locale for Android Espresso Testing

It is possible to set a locale, different than the default device's locale, with the locale parameter.

Please use the CA format (country name abbreviation). For example: DE for Germany.

Copy code
curl -u api_key:api_secret \
-X POST "https://api.testingbot.com/v1/app-automate/espresso/:id/run" \
-d '{ "espressoOptions": { "locale": "DE" }, "capabilities":[{"platform":"ANDROID", "version":12, "deviceName":"Pixel 6", "platformName":"Android"}]}' \
-H "Content-Type: application/json"

Change timezone for Android Espresso

It might be necessary during your tests to change the timezone to a different timezone than the default one on the device (UTC).

Please use a timezone format from the list of timezones.

Copy code
curl -u api_key:api_secret \
-X POST "https://api.testingbot.com/v1/app-automate/espresso/:id/run" \
-d '{ "espressoOptions": { "timeZone": "New_York" }, "capabilities":[{"platform":"ANDROID", "version":12, "deviceName":"Pixel 6", "platformName":"Android"}]}' \
-H "Content-Type: application/json"