summaryrefslogtreecommitdiff
path: root/test/fixtures
diff options
context:
space:
mode:
authorThiago Marcos P. Santos <thiago@mapbox.com>2017-01-24 14:39:08 +0200
committerThiago Marcos P. Santos <tmpsantos@gmail.com>2017-07-07 14:28:52 +0300
commit69c8f602de9ab087dd841dfabf33a72d46672673 (patch)
tree13f8e58db30927a88e5e71f45cd6c35b8bf502c8 /test/fixtures
parent407fbc70b1dc6dab6b7aa5a4b9c57b4e08906c79 (diff)
downloadqtlocation-mapboxgl-69c8f602de9ab087dd841dfabf33a72d46672673.tar.gz
[tests] Add unit test for tile prefetching
Diffstat (limited to 'test/fixtures')
-rw-r--r--test/fixtures/map/prefetch/empty.json5
-rw-r--r--test/fixtures/map/prefetch/expected.pngbin0 -> 2198 bytes
-rw-r--r--test/fixtures/map/prefetch/style.json24
-rw-r--r--test/fixtures/map/prefetch/tile_green.pngbin0 -> 659 bytes
-rw-r--r--test/fixtures/map/prefetch/tile_red.pngbin0 -> 659 bytes
5 files changed, 29 insertions, 0 deletions
diff --git a/test/fixtures/map/prefetch/empty.json b/test/fixtures/map/prefetch/empty.json
new file mode 100644
index 0000000000..61a8fadcdb
--- /dev/null
+++ b/test/fixtures/map/prefetch/empty.json
@@ -0,0 +1,5 @@
+{
+ "version": 8,
+ "sources": {},
+ "layers": []
+}
diff --git a/test/fixtures/map/prefetch/expected.png b/test/fixtures/map/prefetch/expected.png
new file mode 100644
index 0000000000..e1111b37f7
--- /dev/null
+++ b/test/fixtures/map/prefetch/expected.png
Binary files differ
diff --git a/test/fixtures/map/prefetch/style.json b/test/fixtures/map/prefetch/style.json
new file mode 100644
index 0000000000..b4e163888c
--- /dev/null
+++ b/test/fixtures/map/prefetch/style.json
@@ -0,0 +1,24 @@
+{
+ "version": 8,
+ "name": "Test",
+ "sources": {
+ "raster": {
+ "type": "raster",
+ "tiles": [ "{z}" ],
+ "tileSize": 256,
+ "maxzoom": 20,
+ "minzoom": 0
+ }
+ },
+ "layers": [{
+ "id": "background",
+ "type": "background",
+ "paint": {
+ "background-color": "blue"
+ }
+ }, {
+ "id": "raster",
+ "type": "raster",
+ "source": "raster"
+ }]
+}
diff --git a/test/fixtures/map/prefetch/tile_green.png b/test/fixtures/map/prefetch/tile_green.png
new file mode 100644
index 0000000000..553cd10cd1
--- /dev/null
+++ b/test/fixtures/map/prefetch/tile_green.png
Binary files differ
diff --git a/test/fixtures/map/prefetch/tile_red.png b/test/fixtures/map/prefetch/tile_red.png
new file mode 100644
index 0000000000..5fa561fb92
--- /dev/null
+++ b/test/fixtures/map/prefetch/tile_red.png
Binary files differ