Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Develop
Test
Publish
Monetize
Engage users
Device specifications
Resources
Skip to main content
Performance testing is the process of app testing in areas such as compatibility, reliability speed, response time, stability, and resource usage on Amazon Fire OS devices. You can use this testing to identify and address your app’s performance bottlenecks. Performance testing involves gathering and evaluating key performance indicator (KPI) metrics. To gather KPI metrics, you run a specific set of steps on an Amazon device and then find or calculate the metrics using device resources, such as logs. Make sure to run performance tests before submitting your app to Amazon Appstore. This page provides steps to test different categories of KPIs and includes example code that you can use in automation. This guide covers the following KPIs:

Setup

To get started, install the following software packages on your development computer: In addition to the installing the software packages, you will need to:
  • Set up a path for JAVA_HOME and ANDROID_HOME folders.
  • Enable developer mode on the device and enable USB Debugging. For instructions, see .
  • Capture the serial number of the attached device. To list the serial numbers of physically attached devices, you can use the Android Debug Bridge (ADB) command adb devices -l .

Test strategy

During testing, you launch the app and force stop it several times by using the app launcher intent or the Monkey tool. Between each iteration, you must perform certain actions, such as capturing logs, performing navigation actions, capturing timer values from logs, and capturing memory and RAM usage before force stopping the app. This loop continues for the number of iterations you configure. As network conditions, system load, and other factors can impact the test results, use multiple iterations to average out the interference from external factors. To calculate metric averages, Amazon recommends running a minimum number of iterations for the following test categories.
Performance test categoryMinimum number of iterations recommended
Latency – time to first frame (TTFF)50
Ready-to-use – time to full display (TTFD)10
Memory5
Devices to test: You can use the logs, screenshots, and other artifacts captured from the performance tests for debugging or data use. The Appium device object is force stopped as part of tear-down. The following sections contain code examples that you can add to your test automation script.

Get device type

The following example code shows how to get the device type of the connected device.

Retrieve component name of the main launcher activity

The following example code shows how to retrieve the component name of the main launcher activity. This method fetches the main activity of the app under test and constructs the component name by combining the names of the app package and main activity.

Launch an app using the component name of the main launcher activity

Use the following example code to launch an app using the component name of the main launcher activity. The code uses the componentName variable defined in the previous section, which creates the component name by combining app package and main activity.

Launch an app using the Monkey tool

The following code shows how to launch an app using the Monkey tool.

Force stop an app

The following example code shows how to force stop an app.

General commands

The following sections provide examples of commands you can use in performance testing.

Memory ADB dump log

The proportional set size (PSS) total is the amount of memory consumed by the app on the device. PSS total is used to calculate the memory consumption of an app when it is in the foreground or background.

Write a KPI log file

Use the following example code to write a KPI log file for one iteration.
Last modified on July 23, 2026