Navigation Menu

Skip to content

Commit

Permalink
Update test images
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Dec 15, 2019
1 parent 2e3b57a commit 0d84e35
Show file tree
Hide file tree
Showing 23 changed files with 7 additions and 5 deletions.
8 changes: 4 additions & 4 deletions tests/src/core/testqgscallout.cpp
Expand Up @@ -147,7 +147,7 @@ class TestQgsCallout: public QObject
void manhattanDataDefinedDrawToAllParts();

private:
bool imageCheck( const QString &testName, QImage &image, int mismatchCount = 0 );
bool imageCheck( const QString &testName, QImage &image, unsigned int mismatchCount = 0 );

QString mReport;
QString mTestDataDir;
Expand Down Expand Up @@ -1698,7 +1698,7 @@ void TestQgsCallout::manhattanDataDefinedDrawToAllParts()
// Private helper functions not called directly by CTest
//

bool TestQgsCallout::imageCheck( const QString &testName, QImage &image, int mismatchCount )
bool TestQgsCallout::imageCheck( const QString &testName, QImage &image, unsigned int mismatchCount )
{
//draw background
QImage imageWithBackground( image.width(), image.height(), QImage::Format_RGB32 );
Expand All @@ -1711,12 +1711,12 @@ bool TestQgsCallout::imageCheck( const QString &testName, QImage &image, int mis
QString tempDir = QDir::tempPath() + '/';
QString fileName = tempDir + testName + ".png";
imageWithBackground.save( fileName, "PNG" );
QgsRenderChecker checker;
QgsMultiRenderChecker checker;
checker.setControlPathPrefix( QStringLiteral( "callouts" ) );
checker.setControlName( "expected_" + testName );
checker.setRenderedImage( fileName );
checker.setColorTolerance( 2 );
bool resultFlag = checker.compareImages( testName, mismatchCount );
bool resultFlag = checker.runTest( testName, mismatchCount );
mReport += checker.report();
return resultFlag;
}
Expand Down
4 changes: 3 additions & 1 deletion tests/src/python/test_selective_masking.py
Expand Up @@ -564,7 +564,9 @@ def test_mask_symbollayer_preview(self):
render_function()
self.checker.setControlName(control_name)
self.checker.setRenderedImage(tmp)
self.assertTrue(self.checker.compareImages(control_name))
res = self.checker.compareImages(control_name, 90)
self.report += self.checker.report()
self.assertTrue(res)

def test_mask_with_effect(self):
p = QgsMarkerSymbol.createSimple({'color': '#fdbf6f', 'size': "7"})
Expand Down
Binary file not shown.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 0d84e35

Please sign in to comment.