summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location
diff options
context:
space:
mode:
authorTobrun <tobrun.van.nuland@gmail.com>2018-11-08 13:39:26 +0100
committerTobrun <tobrun@mapbox.com>2018-12-10 16:59:50 +0100
commitd68dfe0551d75fde860f97a94f57fea487afd55e (patch)
tree4f321700db70da693e76153bb66cff6273e7b681 /platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location
parent1374535e632c8ff40de15adacab1e1b0435cc66c (diff)
downloadqtlocation-mapboxgl-d68dfe0551d75fde860f97a94f57fea487afd55e.tar.gz
[android] - move all layer, source, image, light and transition configurations to style.java
Diffstat (limited to 'platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location')
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/LocationLayerControllerTest.kt4
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/utils/MapboxTestingUtils.kt2
2 files changed, 3 insertions, 3 deletions
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/LocationLayerControllerTest.kt b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/LocationLayerControllerTest.kt
index 0554f924f2..aa666eaa25 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/LocationLayerControllerTest.kt
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/LocationLayerControllerTest.kt
@@ -79,7 +79,7 @@ class LocationLayerControllerTest : BaseActivityTest() {
component.isLocationComponentEnabled = true
component.renderMode = RenderMode.NORMAL
uiController.loopMainThreadForAtLeast(MAP_RENDER_DELAY)
- assertThat(mapboxMap.getSource(LOCATION_SOURCE), notNullValue())
+ assertThat(mapboxMap.getStyle().getSource(LOCATION_SOURCE), notNullValue())
}
}
executeComponentTest(componentAction)
@@ -220,7 +220,7 @@ class LocationLayerControllerTest : BaseActivityTest() {
assertThat(component.renderMode, `is`(equalTo(RenderMode.NORMAL)))
// Check that the Source has been re-added to the new map style
- val source: GeoJsonSource? = mapboxMap.getSourceAs(LOCATION_SOURCE)
+ val source: GeoJsonSource? = mapboxMap.getStyle().getSourceAs(LOCATION_SOURCE)
assertThat(source, notNullValue())
// Check that all layers visibilities are set to visible
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/utils/MapboxTestingUtils.kt b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/utils/MapboxTestingUtils.kt
index 7d362a6f76..9ad1e1fc37 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/utils/MapboxTestingUtils.kt
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/location/utils/MapboxTestingUtils.kt
@@ -99,7 +99,7 @@ class MapboxTestingUtils {
fun MapboxMap.addImageFromDrawable(string: String, drawable: Drawable) {
val bitmapFromDrawable = getBitmapFromDrawable(drawable)
- this.addImage(string, bitmapFromDrawable)
+ this.style.addImage(string, bitmapFromDrawable)
}
private fun getBitmapFromDrawable(drawable: Drawable): Bitmap {