diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2017-04-27 15:05:11 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2017-05-04 07:29:08 -0700 |
commit | 89f1ffc6d29d5631dfd322834397ec2247c5c9d7 (patch) | |
tree | 277bd6ca61cbecaa9c659273992da2abbe9a431e /test | |
parent | 806da5d940aed7021f921ab98b9ae8e4e364f732 (diff) | |
download | qtlocation-mapboxgl-89f1ffc6d29d5631dfd322834397ec2247c5c9d7.tar.gz |
[core] UpdateParameters ⇢ TileParameters
Diffstat (limited to 'test')
-rw-r--r-- | test/style/source.test.cpp | 22 | ||||
-rw-r--r-- | test/tile/annotation_tile.test.cpp | 6 | ||||
-rw-r--r-- | test/tile/geojson_tile.test.cpp | 6 | ||||
-rw-r--r-- | test/tile/raster_tile.test.cpp | 12 | ||||
-rw-r--r-- | test/tile/vector_tile.test.cpp | 12 |
5 files changed, 29 insertions, 29 deletions
diff --git a/test/style/source.test.cpp b/test/style/source.test.cpp index a651fd8964..c60a473589 100644 --- a/test/style/source.test.cpp +++ b/test/style/source.test.cpp @@ -11,6 +11,7 @@ #include <mbgl/renderer/sources/render_raster_source.hpp> #include <mbgl/renderer/sources/render_vector_source.hpp> #include <mbgl/renderer/sources/render_geojson_source.hpp> +#include <mbgl/renderer/tile_parameters.hpp> #include <mbgl/util/run_loop.hpp> #include <mbgl/util/string.hpp> @@ -23,7 +24,6 @@ #include <mbgl/map/transform.hpp> #include <mbgl/style/style.hpp> -#include <mbgl/renderer/update_parameters.hpp> #include <mbgl/style/layers/line_layer.hpp> #include <mbgl/annotation/annotation_manager.hpp> #include <mbgl/annotation/annotation_source.hpp> @@ -46,7 +46,7 @@ public: AnnotationManager annotationManager { 1.0 }; style::Style style { threadPool, fileSource, 1.0 }; - UpdateParameters updateParameters { + TileParameters tileParameters { 1.0, MapDebugOptions(), transformState, @@ -150,7 +150,7 @@ TEST(Source, RasterTileEmpty) { RenderRasterSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -181,7 +181,7 @@ TEST(Source, VectorTileEmpty) { RenderVectorSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -212,7 +212,7 @@ TEST(Source, RasterTileFail) { RenderRasterSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -243,7 +243,7 @@ TEST(Source, VectorTileFail) { RenderVectorSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -273,7 +273,7 @@ TEST(Source, RasterTileCorrupt) { RenderRasterSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -307,7 +307,7 @@ TEST(Source, VectorTileCorrupt) { RenderVectorSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -336,7 +336,7 @@ TEST(Source, RasterTileCancel) { RenderRasterSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -365,7 +365,7 @@ TEST(Source, VectorTileCancel) { RenderVectorSource renderSource(*source.impl); renderSource.setObserver(&test.renderSourceObserver); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } @@ -402,7 +402,7 @@ TEST(Source, RasterTileAttribution) { source.baseImpl->loadDescription(test.fileSource); RenderRasterSource renderSource(*source.impl); - renderSource.updateTiles(test.updateParameters); + renderSource.updateTiles(test.tileParameters); test.run(); } diff --git a/test/tile/annotation_tile.test.cpp b/test/tile/annotation_tile.test.cpp index 64d2c8f1f5..4d71c5b0b4 100644 --- a/test/tile/annotation_tile.test.cpp +++ b/test/tile/annotation_tile.test.cpp @@ -6,7 +6,7 @@ #include <mbgl/map/transform.hpp> #include <mbgl/map/query.hpp> #include <mbgl/style/style.hpp> -#include <mbgl/renderer/update_parameters.hpp> +#include <mbgl/renderer/tile_parameters.hpp> #include <mbgl/map/query.hpp> #include <mbgl/text/collision_tile.hpp> #include <mbgl/geometry/feature_index.hpp> @@ -26,7 +26,7 @@ public: AnnotationManager annotationManager { 1.0 }; style::Style style { threadPool, fileSource, 1.0 }; - UpdateParameters updateParameters { + TileParameters tileParameters { 1.0, MapDebugOptions(), transformState, @@ -41,7 +41,7 @@ public: // Don't query stale collision tile TEST(AnnotationTile, Issue8289) { AnnotationTileTest test; - AnnotationTile tile(OverscaledTileID(0, 0, 0), test.updateParameters); + AnnotationTile tile(OverscaledTileID(0, 0, 0), test.tileParameters); auto data = std::make_unique<AnnotationTileData>(); data->layers.emplace("test", AnnotationTileLayer("test")); diff --git a/test/tile/geojson_tile.test.cpp b/test/tile/geojson_tile.test.cpp index 5d3a28c261..a0383f06c9 100644 --- a/test/tile/geojson_tile.test.cpp +++ b/test/tile/geojson_tile.test.cpp @@ -8,7 +8,7 @@ #include <mbgl/util/run_loop.hpp> #include <mbgl/map/transform.hpp> #include <mbgl/style/style.hpp> -#include <mbgl/renderer/update_parameters.hpp> +#include <mbgl/renderer/tile_parameters.hpp> #include <mbgl/style/layers/circle_layer.hpp> #include <mbgl/annotation/annotation_manager.hpp> @@ -27,7 +27,7 @@ public: style::Style style { threadPool, fileSource, 1.0 }; Tileset tileset { { "https://example.com" }, { 0, 22 }, "none" }; - UpdateParameters updateParameters { + TileParameters tileParameters { 1.0, MapDebugOptions(), transformState, @@ -49,7 +49,7 @@ TEST(GeoJSONTile, Issue7648) { mapbox::geometry::point<int16_t>(0, 0) }); - GeoJSONTile tile(OverscaledTileID(0, 0, 0), "source", test.updateParameters, features); + GeoJSONTile tile(OverscaledTileID(0, 0, 0), "source", test.tileParameters, features); StubTileObserver observer; observer.tileChanged = [&] (const Tile&) { diff --git a/test/tile/raster_tile.test.cpp b/test/tile/raster_tile.test.cpp index 5543c3c56f..f841a82e68 100644 --- a/test/tile/raster_tile.test.cpp +++ b/test/tile/raster_tile.test.cpp @@ -8,7 +8,7 @@ #include <mbgl/map/transform.hpp> #include <mbgl/style/style.hpp> #include <mbgl/annotation/annotation_manager.hpp> -#include <mbgl/renderer/update_parameters.hpp> +#include <mbgl/renderer/tile_parameters.hpp> #include <mbgl/renderer/raster_bucket.hpp> using namespace mbgl; @@ -23,7 +23,7 @@ public: style::Style style { threadPool, fileSource, 1.0 }; Tileset tileset { { "https://example.com" }, { 0, 22 }, "none" }; - UpdateParameters updateParameters { + TileParameters tileParameters { 1.0, MapDebugOptions(), transformState, @@ -37,7 +37,7 @@ public: TEST(RasterTile, setError) { RasterTileTest test; - RasterTile tile(OverscaledTileID(0, 0, 0), test.updateParameters, test.tileset); + RasterTile tile(OverscaledTileID(0, 0, 0), test.tileParameters, test.tileset); tile.setError(std::make_exception_ptr(std::runtime_error("test"))); EXPECT_FALSE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); @@ -46,7 +46,7 @@ TEST(RasterTile, setError) { TEST(RasterTile, onError) { RasterTileTest test; - RasterTile tile(OverscaledTileID(0, 0, 0), test.updateParameters, test.tileset); + RasterTile tile(OverscaledTileID(0, 0, 0), test.tileParameters, test.tileset); tile.onError(std::make_exception_ptr(std::runtime_error("test"))); EXPECT_FALSE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); @@ -55,7 +55,7 @@ TEST(RasterTile, onError) { TEST(RasterTile, onParsed) { RasterTileTest test; - RasterTile tile(OverscaledTileID(0, 0, 0), test.updateParameters, test.tileset); + RasterTile tile(OverscaledTileID(0, 0, 0), test.tileParameters, test.tileset); tile.onParsed(std::make_unique<RasterBucket>(UnassociatedImage{})); EXPECT_TRUE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); @@ -64,7 +64,7 @@ TEST(RasterTile, onParsed) { TEST(RasterTile, onParsedEmpty) { RasterTileTest test; - RasterTile tile(OverscaledTileID(0, 0, 0), test.updateParameters, test.tileset); + RasterTile tile(OverscaledTileID(0, 0, 0), test.tileParameters, test.tileset); tile.onParsed(nullptr); EXPECT_FALSE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); diff --git a/test/tile/vector_tile.test.cpp b/test/tile/vector_tile.test.cpp index 244892f220..37bfe8512d 100644 --- a/test/tile/vector_tile.test.cpp +++ b/test/tile/vector_tile.test.cpp @@ -9,7 +9,7 @@ #include <mbgl/map/query.hpp> #include <mbgl/style/style.hpp> #include <mbgl/style/layers/symbol_layer.hpp> -#include <mbgl/renderer/update_parameters.hpp> +#include <mbgl/renderer/tile_parameters.hpp> #include <mbgl/renderer/symbol_bucket.hpp> #include <mbgl/text/collision_tile.hpp> #include <mbgl/geometry/feature_index.hpp> @@ -29,7 +29,7 @@ public: style::Style style { threadPool, fileSource, 1.0 }; Tileset tileset { { "https://example.com" }, { 0, 22 }, "none" }; - UpdateParameters updateParameters { + TileParameters tileParameters { 1.0, MapDebugOptions(), transformState, @@ -43,7 +43,7 @@ public: TEST(VectorTile, setError) { VectorTileTest test; - VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.updateParameters, test.tileset); + VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.tileParameters, test.tileset); tile.setError(std::make_exception_ptr(std::runtime_error("test"))); EXPECT_FALSE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); @@ -52,7 +52,7 @@ TEST(VectorTile, setError) { TEST(VectorTile, onError) { VectorTileTest test; - VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.updateParameters, test.tileset); + VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.tileParameters, test.tileset); tile.onError(std::make_exception_ptr(std::runtime_error("test"))); EXPECT_FALSE(tile.isRenderable()); EXPECT_TRUE(tile.isLoaded()); @@ -61,7 +61,7 @@ TEST(VectorTile, onError) { TEST(VectorTile, Issue7615) { VectorTileTest test; - VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.updateParameters, test.tileset); + VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.tileParameters, test.tileset); style::SymbolLayer symbolLayer("symbol", "source"); auto symbolBucket = std::make_shared<SymbolBucket>( @@ -94,7 +94,7 @@ TEST(VectorTile, Issue7615) { TEST(VectorTile, Issue8542) { VectorTileTest test; - VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.updateParameters, test.tileset); + VectorTile tile(OverscaledTileID(0, 0, 0), "source", test.tileParameters, test.tileset); // Query before data is set std::vector<Feature> result; |