From 26ba8e185521e4785b3b7f2cb3ec025945de198d Mon Sep 17 00:00:00 2001 From: Bart Louwers Date: Thu, 23 May 2024 19:20:20 +0200 Subject: [PATCH] Add run configuration for Instrumentation Tests Android (#2422) --- .../Instrumentation_Tests.xml | 64 +++++++++++++++++++ platform/android/DEVELOPING.md | 6 +- platform/android/settings.gradle | 4 +- 3 files changed, 68 insertions(+), 6 deletions(-) create mode 100644 platform/android/.idea/runConfigurations/Instrumentation_Tests.xml diff --git a/platform/android/.idea/runConfigurations/Instrumentation_Tests.xml b/platform/android/.idea/runConfigurations/Instrumentation_Tests.xml new file mode 100644 index 000000000..4cdd79fb8 --- /dev/null +++ b/platform/android/.idea/runConfigurations/Instrumentation_Tests.xml @@ -0,0 +1,64 @@ + + + + + \ No newline at end of file diff --git a/platform/android/DEVELOPING.md b/platform/android/DEVELOPING.md index 371687071..d5b75adef 100644 --- a/platform/android/DEVELOPING.md +++ b/platform/android/DEVELOPING.md @@ -41,14 +41,10 @@ More information on working on the render tests can be found [in the wiki](https ## Instrumentation Tests -To run the instrumentatin tests, find the `MapLibreAndroidTestApp` project in the sidebar, go to `src > androidTest`, right click and select "Run 'All Tests'". - -image +To run the instrumentation tests, choose the "Instrumentation Tests" run configuration. Your device needs remain unlocked for the duration of the tests. -The instrumentation tests take a long time to run (depending on the device, about an hour). You can modify the run configuration in Android Studio and add the regex `^(?!.*org\.maplibre\.android\.benchmark).*$` to exclude the benchmark. - ### AWS Device Farm The instrumentation tests are running on AWS Device Farm. To see the results and the logs, go to: diff --git a/platform/android/settings.gradle b/platform/android/settings.gradle index b27f2384f..35dabc60a 100644 --- a/platform/android/settings.gradle +++ b/platform/android/settings.gradle @@ -3,4 +3,6 @@ include ':MapLibreAndroid', ':MapLibreAndroidTestApp', ':MapLibreAndroidLint' rootProject.name = "MapLibre Native for Android" def renderTestProjectDir = new File(rootDir, '../../render-test/android') -includeBuild(renderTestProjectDir) \ No newline at end of file +includeBuild(renderTestProjectDir) { + name ="Render Test App" +} \ No newline at end of file