summaryrefslogtreecommitdiff
path: root/test/gl
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-10-29 14:29:16 +0200
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-10-31 11:22:46 +0200
commit56808731b699d7750726cd88dd06516c63d7f2f0 (patch)
tree7839dffdd0eec33f6ebd2cfa9195f7408ac6c289 /test/gl
parent3f314682fa2f2701c0d1c7e863013ce254a23afd (diff)
downloadqtlocation-mapboxgl-56808731b699d7750726cd88dd06516c63d7f2f0.tar.gz
Remove style::Layer::is()/as()
Diffstat (limited to 'test/gl')
-rw-r--r--test/gl/context.test.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/gl/context.test.cpp b/test/gl/context.test.cpp
index 179ce5de53..2561c84591 100644
--- a/test/gl/context.test.cpp
+++ b/test/gl/context.test.cpp
@@ -94,7 +94,9 @@ TEST(GLContextMode, Shared) {
map.setLatLngZoom({ 37.8, -122.5 }, 10);
// Set transparent background layer.
- map.getStyle().getLayer("background")->as<BackgroundLayer>()->setBackgroundColor( { { 1.0f, 0.0f, 0.0f, 0.5f } } );
+ auto layer = map.getStyle().getLayer("background");
+ ASSERT_EQ(LayerType::Background, layer->getType());
+ static_cast<BackgroundLayer*>(layer)->setBackgroundColor( { { 1.0f, 0.0f, 0.0f, 0.5f } } );
{
// Custom rendering outside of GL Native render loop.