summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDKTestApp
diff options
context:
space:
mode:
authorŁukasz Paczos <lukas.paczos@gmail.com>2018-11-19 16:45:05 +0100
committerŁukasz Paczos <lukasz.paczos@mapbox.com>2018-11-20 12:20:50 +0100
commite08e143c123c0fd542f1a1a1a615d284ecd2db45 (patch)
tree34819dda7a0184b914e36e052381a533d0d29440 /platform/android/MapboxGLAndroidSDKTestApp
parentd0520d02f123557c7c7361053ab1e56318912fa3 (diff)
downloadqtlocation-mapboxgl-e08e143c123c0fd542f1a1a1a615d284ecd2db45.tar.gz
[android] getting a constant layer filter fix
Diffstat (limited to 'platform/android/MapboxGLAndroidSDKTestApp')
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/CircleLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillExtrusionLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/HeatmapLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/LineLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/SymbolLayerTest.java5
-rw-r--r--platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/layer.junit.ejs5
7 files changed, 35 insertions, 0 deletions
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/CircleLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/CircleLayerTest.java
index 4101c0ffa1..2b1af88e32 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/CircleLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/CircleLayerTest.java
@@ -112,6 +112,11 @@ public class CircleLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillExtrusionLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillExtrusionLayerTest.java
index 6e4a8d628f..4471cc4e66 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillExtrusionLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillExtrusionLayerTest.java
@@ -112,6 +112,11 @@ public class FillExtrusionLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillLayerTest.java
index 2b50279c89..a1afc544aa 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/FillLayerTest.java
@@ -112,6 +112,11 @@ public class FillLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/HeatmapLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/HeatmapLayerTest.java
index cfe135ae78..01d1bc2c61 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/HeatmapLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/HeatmapLayerTest.java
@@ -112,6 +112,11 @@ public class HeatmapLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/LineLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/LineLayerTest.java
index 861730134e..ba4f23ab5d 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/LineLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/LineLayerTest.java
@@ -112,6 +112,11 @@ public class LineLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/SymbolLayerTest.java b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/SymbolLayerTest.java
index 81b32ca6ab..5b985bdba0 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/SymbolLayerTest.java
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/SymbolLayerTest.java
@@ -114,6 +114,11 @@ public class SymbolLayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/layer.junit.ejs b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/layer.junit.ejs
index dc6a181633..aca6bbd0ec 100644
--- a/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/layer.junit.ejs
+++ b/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/style/layer.junit.ejs
@@ -130,6 +130,11 @@ public class <%- camelize(type) %>LayerTest extends BaseActivityTest {
Expression filter = eq(get("undefined"), literal(1.0));
layer.setFilter(filter);
assertEquals(layer.getFilter().toString(), filter.toString());
+
+ // Set constant
+ filter = literal(true);
+ layer.setFilter(filter);
+ assertEquals(layer.getFilter().toString(), filter.toString());
});
}