diff options
author | Langston Smith <langston.smith@mapbox.com> | 2019-08-01 20:46:01 -0700 |
---|---|---|
committer | langsmith <langstonlmcs@gmail.com> | 2019-09-30 18:54:18 -0700 |
commit | a8a8ccd5ff48c50d827a4face97995272e474b69 (patch) | |
tree | 1ac1f0d7624f28d1e8a67d8272485d1faa53ed51 | |
parent | 96a98bdf3ab79fcd3d5bd3f21232d3a45613570c (diff) | |
download | qtlocation-mapboxgl-a8a8ccd5ff48c50d827a4face97995272e474b69.tar.gz |
[android] adding mocked context to pulsing circle test
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/src/test/java/com/mapbox/mapboxsdk/location/LocationAnimatorCoordinatorTest.kt | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/test/java/com/mapbox/mapboxsdk/location/LocationAnimatorCoordinatorTest.kt b/platform/android/MapboxGLAndroidSDK/src/test/java/com/mapbox/mapboxsdk/location/LocationAnimatorCoordinatorTest.kt index 9039f8bb69..cc9367bd2d 100644 --- a/platform/android/MapboxGLAndroidSDK/src/test/java/com/mapbox/mapboxsdk/location/LocationAnimatorCoordinatorTest.kt +++ b/platform/android/MapboxGLAndroidSDK/src/test/java/com/mapbox/mapboxsdk/location/LocationAnimatorCoordinatorTest.kt @@ -1,6 +1,7 @@ package com.mapbox.mapboxsdk.location import android.animation.Animator +import android.content.Context import android.location.Location import android.util.SparseArray import android.view.animation.LinearInterpolator @@ -21,7 +22,6 @@ import org.junit.Test import org.junit.runner.RunWith import org.mockito.Mockito import org.robolectric.RobolectricTestRunner -import org.robolectric.RuntimeEnvironment @RunWith(RobolectricTestRunner::class) class LocationAnimatorCoordinatorTest { @@ -37,8 +37,9 @@ class LocationAnimatorCoordinatorTest { @Before fun setUp() { - locationComponentOptions = LocationComponentOptions.builder( - RuntimeEnvironment.systemContext) + val context: Context = mockk(relaxed = true) + + locationComponentOptions = LocationComponentOptions.builder(context) .pulsingCircleEnabled(true) .build() |