diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2016-12-21 12:56:34 +0100 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2017-01-05 15:22:48 +0100 |
commit | 20615a2c15a3b7e0a002d98146d25f29c8631ff3 (patch) | |
tree | 15631f7d72af3d2c320160d18e88f3419b593b3e /platform/android/tests | |
parent | ed4e7a11340e3ee4e553591753bdadd78413b49b (diff) | |
download | qtlocation-mapboxgl-20615a2c15a3b7e0a002d98146d25f29c8631ff3.tar.gz |
[android] improve test runner by allowing selective execution of tests
Diffstat (limited to 'platform/android/tests')
-rw-r--r-- | platform/android/tests/README.md | 9 | ||||
-rw-r--r-- | platform/android/tests/docs/CORE_TESTS.md | 21 |
2 files changed, 26 insertions, 4 deletions
diff --git a/platform/android/tests/README.md b/platform/android/tests/README.md index 69e75b693b..8c4d29e831 100644 --- a/platform/android/tests/README.md +++ b/platform/android/tests/README.md @@ -3,7 +3,8 @@ ## Testing We currently support the following types of testing on the Mapbox Android SDK: - - [Unit tests](https://github.com/mapbox/mapbox-gl-native/blob/3447-Add-test-documentation/platform/android/tests/docs/UNIT_TESTS.md) using [JUnit](http://developer.android.com/tools/testing-support-library/index.html#AndroidJUnitRunner) - - [UI tests](https://github.com/mapbox/mapbox-gl-native/blob/3447-Add-test-documentation/platform/android/tests/docs/UI_TESTS.md) using [Espresso](http://developer.android.com/tools/testing-support-library/index.html#Espresso) - - [Exerciser](https://github.com/mapbox/mapbox-gl-native/blob/3447-Add-test-documentation/platform/android/tests/docs/EXERCISER_TESTS.md) tests using [Monkey](http://developer.android.com/tools/help/monkey.html) or [Build-in Fuzz test](http://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-built-in-fuzz.html) - - [Performance tests](https://github.com/mapbox/mapbox-gl-native/blob/3447-Add-test-documentation/platform/android/tests/docs/PERFORMANCE_TESTS.md) using [Systrace](https://codelabs.developers.google.com/codelabs/android-perf-testing/index.html?index=..%2F..%2Fbabbq-2015&viewga=UA-68632703-1#0) + - [Unit tests](docs/UNIT_TESTS.md) using [JUnit](http://developer.android.com/tools/testing-support-library/index.html#AndroidJUnitRunner) + - [UI tests](docs/UI_TESTS.md) using [Espresso](http://developer.android.com/tools/testing-support-library/index.html#Espresso) + - [Exerciser](docs/EXERCISER_TESTS.md) tests using [Monkey](http://developer.android.com/tools/help/monkey.html) or [Build-in Fuzz test](http://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-built-in-fuzz.html) + - [Performance tests](docs/PERFORMANCE_TESTS.md) using [Systrace](https://codelabs.developers.google.com/codelabs/android-perf-testing/index.html?index=..%2F..%2Fbabbq-2015&viewga=UA-68632703-1#0) + - [Core tests](docs/CORE_TESTS.md) using [Google Test](https://github.com/google/googletest) to run the unit tests written for the core rendering component of Mapbox GL
\ No newline at end of file diff --git a/platform/android/tests/docs/CORE_TESTS.md b/platform/android/tests/docs/CORE_TESTS.md new file mode 100644 index 0000000000..b9cd7bcc76 --- /dev/null +++ b/platform/android/tests/docs/CORE_TESTS.md @@ -0,0 +1,21 @@ +# Core Tests + +Core tests run the [unit tests](../../../../test) written for the core rendering component of Mapbox GL. + +## Running the tests + +To run the tests, connect a device to your computer, or launch a virtual device. Then run + +``` +$ make run-android-core-test-XXX +``` + +with `XXX` being the architecture of the device (one of `arm-v5`, `arm-v7`, `arm-v8`, `x86`, `x86-64`, or `mips`). This command first builds the library, creates a test program, zips up the assets required for the unit tests, deploys it on the device, runs the test and unpacks the results again on your computer. + +You can also run individual tests by specifying the name like this: + +``` +$ make run-android-core-test-XXX-TileCover.* +``` + +Everything after the last dash is passed as the [`--gtest_filter` argument](https://github.com/google/googletest/blob/master/googletest/docs/AdvancedGuide.md#running-a-subset-of-the-tests) to the Google Test binary. |