Skip to content

Commit

Permalink
Add some test images and tweak test tolerances for utopic
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Nov 29, 2014
1 parent 20f57c9 commit d532af0
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion tests/src/core/testqgsblendmodes.cpp
Expand Up @@ -220,7 +220,7 @@ bool TestQgsBlendModes::imageCheck( QString theTestType )
myChecker.setControlName( "expected_" + theTestType );
myChecker.setMapSettings( mMapSettings );
myChecker.setColorTolerance( 1 );
bool myResultFlag = myChecker.runTest( theTestType );
bool myResultFlag = myChecker.runTest( theTestType, 20 );
mReport += myChecker.report();
return myResultFlag;
}
Expand Down
2 changes: 1 addition & 1 deletion tests/src/core/testqgsgeometry.cpp
Expand Up @@ -420,7 +420,7 @@ void TestQgsGeometry::bufferCheck()
QVERIFY( myPolygon.size() > 0 ); //check that the buffer created a feature
dumpPolygon( myPolygon );
delete mypBufferGeometry;
QVERIFY( renderCheck( "geometry_bufferCheck", "Checking buffer(10,10) of B" ) );
QVERIFY( renderCheck( "geometry_bufferCheck", "Checking buffer(10,10) of B", 10 ) );
}
bool TestQgsGeometry::renderCheck( QString theTestName, QString theComment , int mismatchCount )
{
Expand Down
2 changes: 1 addition & 1 deletion tests/src/core/testqgsinvertedpolygonrenderer.cpp
Expand Up @@ -176,7 +176,7 @@ bool TestQgsInvertedPolygon::imageCheck( QString theTestType, const QgsRectangle
myChecker.setControlName( "expected_" + theTestType );
myChecker.setMapSettings( mMapSettings );
myChecker.setColorTolerance( 20 );
bool myResultFlag = myChecker.runTest( theTestType );
bool myResultFlag = myChecker.runTest( theTestType, 100 );
mReport += myChecker.report();
return myResultFlag;
}
Expand Down
4 changes: 2 additions & 2 deletions tests/src/core/testqgsrenderers.cpp
Expand Up @@ -31,7 +31,7 @@
#include <qgsproviderregistry.h>
#include <qgsmaplayerregistry.h>
//qgis test includes
#include "qgsrenderchecker.h"
#include "qgsmultirenderchecker.h"

/** \ingroup UnitTests
* This is a unit test for the different renderers for vector layers.
Expand Down Expand Up @@ -213,7 +213,7 @@ bool TestQgsRenderers::imageCheck( QString theTestType )
QgsRectangle extent( -118.8888888888887720, 22.8002070393376783, -83.3333333333331581, 46.8719806763287536 );
mMapSettings.setExtent( extent );
mMapSettings.setFlag( QgsMapSettings::ForceVectorOutput );
QgsRenderChecker myChecker;
QgsMultiRenderChecker myChecker;
myChecker.setControlName( "expected_" + theTestType );
myChecker.setMapSettings( mMapSettings );
myChecker.setColorTolerance( 15 );
Expand Down
8 changes: 4 additions & 4 deletions tests/src/python/test_qgsblendmodes.py
Expand Up @@ -117,7 +117,7 @@ def testVectorBlending(self):
checker.setMapSettings(self.mapSettings)
checker.setColorTolerance( 1 )

myResult = checker.runTest("vector_blendmodes", 1500);
myResult = checker.runTest("vector_blendmodes", 20);
myMessage = ('vector blending failed')
assert myResult, myMessage

Expand All @@ -143,7 +143,7 @@ def testVectorFeatureBlending(self):
checker.setMapSettings(self.mapSettings)
checker.setColorTolerance( 1 )

myResult = checker.runTest("vector_featureblendmodes", 1500);
myResult = checker.runTest("vector_featureblendmodes", 20);
myMessage = ('vector feature blending failed')
assert myResult, myMessage

Expand All @@ -168,7 +168,7 @@ def testVectorLayerTransparency(self):
checker.setMapSettings(self.mapSettings)
checker.setColorTolerance( 1 )

myResult = checker.runTest("vector_layertransparency", 1500);
myResult = checker.runTest("vector_layertransparency", 20);
myMessage = ('vector layer transparency failed')
assert myResult, myMessage

Expand All @@ -189,7 +189,7 @@ def testRasterBlending(self):
checker.setColorTolerance( 1 )
checker.setColorTolerance( 1 )

myResult = checker.runTest("raster_blendmodes", 1500);
myResult = checker.runTest("raster_blendmodes", 20);
myMessage = ('raster blending failed')
assert myResult, myMessage

Expand Down
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit d532af0

Please sign in to comment.