Skip to content
Permalink
Browse files

Added multilayer(🥪) test

  • Loading branch information
suricactus authored and nyalldawson committed May 26, 2020
1 parent 64b30b1 commit a7c6f9ceafdc79f9ba45e22843798f1c87f7c24e
@@ -58,6 +58,7 @@ class TestQgsCentroidFillSymbol : public QObject
void centroidFillClipPoints();
void centroidFillClipOnCurrentPartOnly();
void centroidFillClipOnCurrentPartOnlyBiggest();
void centroidFillClipMultiplayerPoints();

private:
bool mTestHasError = false ;
@@ -177,6 +178,27 @@ void TestQgsCentroidFillSymbol::centroidFillClipOnCurrentPartOnlyBiggest()
mCentroidFill->setPointOnAllParts( true );
}

void TestQgsCentroidFillSymbol::centroidFillClipMultiplayerPoints()
{
QgsSimpleFillSymbolLayer simpleFill(QColor(255, 255, 255, 100));

mCentroidFill = mCentroidFill->clone();
mCentroidFill->setClipPoints( true );

mFillSymbol->deleteSymbolLayer( 0 );
mFillSymbol->appendSymbolLayer( simpleFill.clone() );
mFillSymbol->appendSymbolLayer( mCentroidFill->clone() );
mFillSymbol->appendSymbolLayer( simpleFill.clone() );

QVERIFY( imageCheck( "symbol_centroidfill_clip_multilayer" ) );

mCentroidFill->setClipPoints( false );
mFillSymbol->deleteSymbolLayer( 0 );
mFillSymbol->deleteSymbolLayer( 1 );
mFillSymbol->deleteSymbolLayer( 2 );
mFillSymbol->changeSymbolLayer( 0, mCentroidFill );
}

//
// Private helper functions not called directly by CTest
//
Binary file not shown.
Binary file not shown.

0 comments on commit a7c6f9c

Please sign in to comment.
You can’t perform that action at this time.