The first time you start up an app is like the first time you meet someone. Is it love at first sight? Or do they have a stain on their shirt and bad body odor? It’s the same with an app, does it start up quickly and smoothly? Or does it have long loading times and crash? Your customers will expect your app to be fast and responsive, and the best way to demonstrate that is with a quick startup, so that your app always makes a good first impression.
The FireOS Performance Test will help you measure First Frame (Time to Initial Display) to test how fast your app will get up and running.
Set up
To get started you’ll need to:
- Install Java 8 or above
- Install Java Development Kit 17 or higher
- Install Android Studio (with Android SDK (API Level 34))
-
Install Maven
- Hint: The instructions on Maven’s website can be a bit confounding, so:
- If you’re on a Mac, use Homebrew to install it by running
brew install maven
in the terminal - If you’re on Windows, check out this blog post
- If you’re on a Mac, use Homebrew to install it by running
- Hint: The instructions on Maven’s website can be a bit confounding, so:
-
Set up ADB
- Hint: If you’re on a Mac, this blog can help with the
command not found: adb
error
- Hint: If you’re on a Mac, this blog can help with the
Install
Once you’ve done that, you can install the performance tester with these steps:
-
Clone the performance tester repository by running this command in the terminal:
git clone https://github.com/amazonappdev/fireos-perf-testing.git
-
Navigate to the project directory:
cd fireos-perf-testing
-
Build the project and create the JAR:
mvn clean install
Run the test
You can then run the test with the following steps:
- Locate the ZIP file FOSTTIDPerfTesting-distribution.zip file in the 'jar' folder
- Unzip it
- Navigate to FOSTTIDPerfTesting-distribution > Input > APK folder
- Copy the APK file you want to test into the APK folder
- Rename the APK file Input.apk
-
In the terminal, navigate to the new FOSTTIDPerfTesting-distribution folder
`cd FOSTTIDPerfTesting-distribution`
-
Decide which kind of test you want to do:
cool
warm
-
latency
(which does both cool and warm tests)
-
Plug your device in to your computer (if you haven’t already) and select "Allow USB Debugging" (if you haven’t already)
- Be sure that ADB has been set up correctly
-
Get your device serial number (if you don’t already have it on hand) by running
`adb devices`
-
Run the test with this command:
java -jar PerformanceKpi-jar.jar <Test Type> <Device Serial Number)>
If you decide to go with the full latency command, it should look something like this:
java -jar PerformanceKpi-jar.jar latency GCC2DM000000000S
The full latency test can take about an hour to run, so be patient!
You’ll find the test results in a folder called test-output in the FOSTTIDPerfTesting-distribution folder.
That’s all there is to it!
For more details, check out the github repo for the FireOS Performance Test. And if you want to dig even deeper into tests you can do on your app, check out the App Health Insights Dashboard, where you can test app latency, memory use, fluidity, and stability.
If you have any questions or feedback, join us in the the Amazon Appstore Community Space and let us know.
Top comments (0)