OSS Tanbou

build Android instrumented and UI tests with AndroidJUnitRunner, Espresso, and AndroidX Test Core

About these scores

OSS scale score is an unbounded metric that log-compresses and weights Stars, Watchers, Forks, and Contributors. Discovery score is the current OSS scale score minus the score at discovery. Update pace is commits in the last 30 days, growth momentum is the OSS scale score difference within the recent observation window, and OSS health is a 0–100 rating based on available recency, Community Health, and release data.

Stars
1,225
Primary language
Java
License
Apache-2.0
Repository last updated
Sep 28, 2026
On this page

Overview

AndroidX Test is a collection of Android testing libraries including AndroidJUnitRunner, Test Core, JUnit extensions, rules, Espresso, and Orchestrator. Together they support instrumented and UI tests that run on physical devices or emulators with access to Android framework APIs.

Features and best fit

Based on official documentation; not hands-on tested · Content checked:

Key features

Run JUnit tests on Android devices with AndroidJUnitRunner

Instrumented tests run in a test APK on devices or emulators and can access Android context and framework APIs while using JUnit 4.

Sources: [4]

Automate View UI interactions with Espresso

Espresso adds View matching, interaction, and assertions for UI tests and is typically used in the same androidTest source set as the runner and rules libraries.

Sources: [3][2]

Combine Core, JUnit extensions, rules, and Orchestrator as needed

Separate artifacts provide ActivityScenario and other Core APIs, AndroidJUnit4 integration, test rules, and isolated test-process execution through Orchestrator.

Sources: [2]

Best fit

Fits integration and UI tests that require real Android framework behavior

Use instrumented tests when a local JVM test cannot reproduce Activity, Instrumentation, device UI, or other platform behavior accurately.

Sources: [4]

Before adoption

Stable versions differ by artifact; use the official release table

As of 2026-10-03, the official table lists Core 1.7.0, Runner/Rules 1.7.0, ext.junit 1.3.0, Espresso 3.7.0, and Orchestrator 1.6.1 as stable. GitHub Releases are not the canonical version source.

Sources: [2][1]

Instrumented tests are higher-fidelity but slower than local tests

The official guide recommends instrumented tests only where real-device framework behavior is needed because they run on physical devices or emulators and cost more time than local tests.

Sources: [4]

Keep test-only libraries in androidTestImplementation

Most AndroidX Test dependencies belong on the test APK classpath through androidTestImplementation. Exceptions such as idling-resource may need implementation when production code references their APIs.

Sources: [3]

Official sources

  1. [1]android/android-test README(2026-10-03)
  2. [2]AndroidX Test release notes(2026-10-03)
  3. [3]AndroidX Test project setup(2026-10-03)
  4. [4]Build instrumented tests(2026-10-03)
  5. [5]AndroidX Test Apache-2.0 license(2026-10-03)
Supplemental curator note

These are the core libraries for tests that must run on a real Android device or emulator. GitHub Releases are not the canonical current-version source; use the AndroidX release notes and Google Maven when selecting dependency versions.

Try it in 3 steps

  1. 1

    Add stable AndroidX Test dependencies

    Add the stable Google Maven artifacts to the app module's build.gradle or build.gradle.kts.

    Add runner 1.7.0, ext:junit 1.3.0, and espresso-core 3.7.0 with androidTestImplementation
  2. 2

    Configure AndroidJUnitRunner

    Set the instrumentation runner in android.defaultConfig and place tests under src/androidTest.

    testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
  3. 3

    Run instrumented tests on a device or emulator

    Run against connected Android targets and inspect the generated androidTests/connected report.

    ./gradlew connectedAndroidTest
Check the official README

Growth

Growth trends · Last 30 days

1,225 Stars

Trend data is still being collected.

Development activity

Last 90 days · weekly

Commits (last 30 days)
9
Open PRs
128

Development activity is still being collected.

Built with

Categories and tags

GitHub data

GitHub dataView detailed GitHub data
Stars
1,225
Forks
344
Watchers
125
Open issues
211
Contributors
42
Owner type
Organization
Primary language
Java
License
Apache-2.0
Repository last updated
Sep 28, 2026
Write a related article

Share a guide or use case for this OSS in Markdown. Articles are published after administrator approval.

Report incorrect information

Tell us if any listing information is incorrect or outdated.

After reading this page, do you know what to do next?