• Home
Name Date Size #Lines LOC

..--

src/08-Apr-2025-7,7255,226

README.mdD08-Apr-20251.1 KiB2718

build.gradleD08-Apr-20251.7 KiB6250

README.md

1# Webkit library instrumentation tests
2
3This project contains the instrumentation tests for the [webkit](/webkit/webkit) library.
4
5The tests are located in a separate module to allow the use of multiple
6[product flavors](https://developer.android.com/build/build-variants#product-flavors)
7to build and run the tests against different targetSdk versions.
8
9This is necessary in order to test dark mode functionality, which changes depending on `targetSdk`
10between `32` and `33`.
11
12
13## Source sets
14Tests that do not depend on a particular `targetSdk` version should be added to the default `androidTest` source set.
15
16Tests that require a particular `targetSdk` version should be added to the appropriate
17[source set](https://developer.android.com/build/build-variants#sourcesets).
18
19## Running tests from Android Studio
20Tests can be run as normal in Android Studio. You must use the "Build Variants" menu to select
21the product flavor to run. Use one of
22
23* `targetSdkLatestDebug`
24* `targetSdk32Debug`
25
26You must select the corresponding build variant in order to run tests located outside the shared
27source set.