Add statusbar test harness app

This commit is contained in:
ajp_anton
2026-07-01 19:39:49 +00:00
parent 5df8bd9e78
commit 7be5f64262
13 changed files with 1129 additions and 0 deletions
+37
View File
@@ -116,3 +116,40 @@ Release builds require local signing configuration:
```bash
./gradlew assembleRelease
```
## Test Harness
The repository also includes a small companion app for compatibility testing.
It is not required for normal use of the module. It creates repeatable
statusbar scenarios such as opaque, transparent, fullscreen, privacy-indicator,
and notification states:
```bash
./gradlew :test-harness:assembleDebug
adb install -r test-harness/build/outputs/apk/debug/test-harness-debug.apk
adb shell am start -n se.ajpanton.statusbartweak.harness/.MainActivity
```
Automation can launch scenarios directly:
```bash
adb shell am start -n se.ajpanton.statusbartweak.harness/.ScenarioActivity --es scenario fullscreen_landscape
adb shell am start -n se.ajpanton.statusbartweak.harness/.MainActivity --es command post_normal
```
Useful scenario values include `opaque_light`, `opaque_dark`, `transparent`,
`fullscreen_portrait`, `fullscreen_landscape`, `camera`, `microphone`, and
`camera_microphone`.
Useful command values include `post_normal`, `post_ongoing`, `post_grouped`,
`update`, `start_chronometer`, `start_churn`, `stop_churn`, `start_media`,
`start_foreground`, `stop_service`, and `clear`.
Battery charging state is controlled by Android system commands rather than by
the harness APK:
```bash
adb shell cmd battery set status 2
adb shell cmd battery set level 80
adb shell cmd battery reset
```