Skip to content
Permalink
Browse files

Add unit test for composermap zebra style

  • Loading branch information
mhugent committed Oct 5, 2012
1 parent 51d97ff commit 53305f0d62a5a03c6fdd2b758ad834d5abae12c1
@@ -38,6 +38,7 @@ class TestQgsComposerMap: public QObject
void grid(); //test if grid and grid annotation works
void overviewMap(); //test if overview map frame works
void uniqueId(); //test if map id is adapted when doing copy paste
void zebraStyle(); //test zebra map border style

private:
QgsComposition* mComposition;
@@ -161,5 +162,16 @@ void TestQgsComposerMap::uniqueId()
QVERIFY( oldId != newId );
}

void TestQgsComposerMap::zebraStyle()
{
mComposerMap->setGridFrameStyle( QgsComposerMap::Zebra );
mComposerMap->setGridEnabled( true );

QgsCompositionChecker checker( "Composer map zebra", mComposition, QString( QString( TEST_DATA_DIR ) + QDir::separator() +
"control_images" + QDir::separator() + "expected_composermap" + QDir::separator() + "composermap_zebra_style.png" ) );
bool testResult = checker.testComposition();
QVERIFY( testResult );
}

QTEST_MAIN( TestQgsComposerMap )
#include "moc_testqgscomposermap.cxx"
Binary file not shown.

0 comments on commit 53305f0

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