Drive all levels through UI instrumentation
This commit is contained in:
20
README.md
20
README.md
@@ -48,7 +48,8 @@ Available commands:
|
||||
| `bash ./AndroidProjectTooling.sh` | Provision or refresh the local Android/JDK toolchain only. | Toolchain under `./jdk` and `./android-sdk` |
|
||||
| `bash ./AndroidProjectTooling.sh --test` | Compile host Git, set `GITHUG_TEST_GIT_BINARY`, and run JVM unit tests. | Test reports under `app/build/reports/` |
|
||||
| `bash ./AndroidProjectTooling.sh --clean-test` | Compile host Git, clean Gradle outputs, set `GITHUG_TEST_GIT_BINARY`, and run JVM unit tests. | Fresh test reports under `app/build/reports/` |
|
||||
| `bash ./AndroidProjectTooling.sh --test-emulator` | Install emulator packages if needed, create/start the project test AVD, compile Android Git, and run debug instrumentation tests. | Instrumentation reports under `app/build/reports/androidTests/` |
|
||||
| `bash ./AndroidProjectTooling.sh --test-emulator` | Install emulator packages if needed, create/start the visible project test AVD, compile Android Git, and run debug instrumentation tests. | Instrumentation reports under `app/build/reports/androidTests/` |
|
||||
| `bash ./AndroidProjectTooling.sh --test-emulator --hide-emulator-window` | Run the same emulator instrumentation tests without showing the emulator window. | Instrumentation reports under `app/build/reports/androidTests/` |
|
||||
| `bash ./AndroidProjectTooling.sh --build` | Build the debug APK. | `app/build/outputs/apk/debug/githug-android-debug-v<versionCode>.apk` |
|
||||
| `bash ./AndroidProjectTooling.sh --build-release-aab` | Build the release Android App Bundle. | `app/build/outputs/bundle/release/githug-android-release-v<versionCode>.aab` |
|
||||
| `bash ./AndroidProjectTooling.sh --compile-git` | Compile Git for the development host and all Android target ABIs. | Host and Android `libgit.so` binaries |
|
||||
@@ -65,6 +66,21 @@ To run instrumentation tests on an Android emulator:
|
||||
bash ./AndroidProjectTooling.sh --test-emulator
|
||||
```
|
||||
|
||||
The emulator window is shown by default so UI instrumentation can be followed visually. Add `--hide-emulator-window` for headless runs:
|
||||
|
||||
```bash
|
||||
bash ./AndroidProjectTooling.sh --test-emulator --hide-emulator-window
|
||||
```
|
||||
|
||||
Test outputs and logs are written under project-local build directories:
|
||||
|
||||
- JVM test HTML report: `app/build/reports/tests/testDebugUnitTest/index.html`
|
||||
- JVM test XML results: `app/build/test-results/testDebugUnitTest/`
|
||||
- Emulator instrumentation HTML report: `app/build/reports/androidTests/connected/debug/index.html`
|
||||
- Emulator instrumentation XML/results: `app/build/outputs/androidTest-results/connected/debug/`
|
||||
- Per-test emulator logcat files: `app/build/outputs/androidTest-results/connected/debug/<device-name>/logcat-*.txt`
|
||||
- Emulator startup log: `build/reports/android-emulator.log`
|
||||
|
||||
To build installable/debuggable artifacts:
|
||||
|
||||
```bash
|
||||
@@ -114,7 +130,7 @@ Options:
|
||||
| --- | --- | --- |
|
||||
| `bash ./AndroidProjectTooling.sh --test` | Ensure the host Git binary is current, then run tests with it. | `build/host-git/libgit.so` and test reports |
|
||||
| `bash ./AndroidProjectTooling.sh --clean-test` | Ensure the host Git binary is current, clean Gradle outputs, then run tests with it. | `build/host-git/libgit.so` and fresh test reports |
|
||||
| `bash ./AndroidProjectTooling.sh --test-emulator` | Ensure Android ABI Git binaries are current, then run instrumentation tests on the project AVD. | Android `libgit.so` binaries and instrumentation reports |
|
||||
| `bash ./AndroidProjectTooling.sh --test-emulator` | Ensure Android ABI Git binaries are current, then run instrumentation tests on the visible project AVD. | Android `libgit.so` binaries and instrumentation reports |
|
||||
| `bash ./AndroidProjectTooling.sh --compile-git` | Ensure host Git and Android ABI Git binaries are current. | Host and Android outputs |
|
||||
|
||||
Android ABI outputs are generated files and are ignored by git:
|
||||
|
||||
Reference in New Issue
Block a user