Skip to content
Permalink
Browse files
Also test the opacity parameter within the external layer
  • Loading branch information
mhugent authored and nyalldawson committed Apr 17, 2021
1 parent 8b0e292 commit 903c309572346e26abcacfcfdbabbba5b0cc71e3
Showing with 2 additions and 1 deletion.
  1. +2 −1 tests/src/server/wms/test_qgsserver_wms_parameters.cpp
@@ -50,6 +50,7 @@ void TestQgsServerWmsParameters::external_layers()
query.addQueryItem( "external_layer_1:layers", "layer_1_name" );
query.addQueryItem( "external_layer_2:url", "http://url_2" );
query.addQueryItem( "external_layer_2:layers", "layer_2_name" );
query.addQueryItem( "external_layer_2:opacities", "100" );
query.addQueryItem( "OPACITIES", "255,200,125" );

QgsWms::QgsWmsParameters parameters( query );
@@ -66,7 +67,7 @@ void TestQgsServerWmsParameters::external_layers()

layer_params = layers_params[2];
QCOMPARE( layer_params.mNickname, QString( "external_layer_2" ) );
QCOMPARE( layer_params.mExternalUri, QString( "layers=layer_2_name&url=http://url_2" ) );
QCOMPARE( layer_params.mExternalUri, QString( "layers=layer_2_name&opacities=100&url=http://url_2" ) );

//test if opacities are also applied to external layers
QCOMPARE( layers_params[0].mOpacity, 255 );

0 comments on commit 903c309

Please sign in to comment.