Skip to content
Permalink
Browse files

various windows test fixes:

* .gitignore sort and remove duplicates
* show more warnings in tests
* add/update masks for rendering checks on windows
* fix delimited text provider tests
* disable QgsLogger and QgsPalLabelingServer on windows
  • Loading branch information
jef-n committed Jul 5, 2015
1 parent fbad680 commit 5b54e260d4cf6aea6e04e7c4a1bfb4c5a6a1b785
Showing with 316 additions and 203 deletions.
  1. +42 −43 .gitignore
  2. +4 −2 scripts/generate_test_mask_image.py
  3. +19 −1 src/core/qgsfontutils.cpp
  4. +37 −42 src/core/qgsrenderchecker.cpp
  5. +3 −3 src/core/qgsrenderchecker.h
  6. +2 −2 src/providers/delimitedtext/qgsdelimitedtextfile.cpp
  7. +1 −0 src/providers/spatialite/qgsspatialiteprovider.cpp
  8. +1 −1 tests/src/analysis/CMakeLists.txt
  9. +1 −1 tests/src/app/CMakeLists.txt
  10. +1 −1 tests/src/core/CMakeLists.txt
  11. +19 −12 tests/src/core/testqgsblendmodes.cpp
  12. +8 −2 tests/src/core/testqgscomposermodel.cpp
  13. +7 −2 tests/src/core/testqgscomposermultiframe.cpp
  14. +12 −12 tests/src/core/testqgscomposerobject.cpp
  15. +11 −4 tests/src/core/testqgscomposertable.cpp
  16. +7 −7 tests/src/core/testqgscomposition.cpp
  17. +13 −9 tests/src/core/testqgsdiagram.cpp
  18. +8 −0 tests/src/core/testqgsfontutils.cpp
  19. +18 −12 tests/src/core/testqgsmaprenderer.cpp
  20. +14 −4 tests/src/core/testqgsmapsettings.cpp
  21. +22 −15 tests/src/core/testqgsrasterlayer.cpp
  22. +15 −8 tests/src/core/testqgsrenderers.cpp
  23. +1 −1 tests/src/gui/CMakeLists.txt
  24. +1 −1 tests/src/gui/testqgsscalecombobox.cpp
  25. +1 −1 tests/src/providers/CMakeLists.txt
  26. +1 −1 tests/src/providers/grass/CMakeLists.txt
  27. +10 −5 tests/src/python/CMakeLists.txt
  28. +2 −2 tests/src/python/test_provider_shapefile.py
  29. +1 −2 tests/src/python/test_qgsatlascomposition.py
  30. +28 −5 tests/src/python/test_qgsdelimitedtextprovider.py
  31. +6 −2 tests/src/python/test_qgspallabeling_base.py
  32. BIN tests/testdata/control_images/expected_atlas_autoscale1/expected_atlas_autoscale1_mask.png
  33. BIN tests/testdata/control_images/expected_atlas_autoscale2/expected_atlas_autoscale2_mask.png
  34. BIN ...tdata/control_images/expected_atlas_autoscale_old_api1/expected_atlas_autoscale_old_api1_mask.png
  35. BIN ...tdata/control_images/expected_atlas_autoscale_old_api2/expected_atlas_autoscale_old_api2_mask.png
  36. BIN tests/testdata/control_images/expected_atlas_filtering1/expected_atlas_filtering1_mask.png
  37. BIN tests/testdata/control_images/expected_atlas_fixedscale1/expected_atlas_fixedscale1_mask.png
  38. BIN tests/testdata/control_images/expected_atlas_fixedscale2/expected_atlas_fixedscale2_mask.png
  39. BIN ...ata/control_images/expected_atlas_fixedscale_old_api1/expected_atlas_fixedscale_old_api1_mask.png
  40. BIN ...ata/control_images/expected_atlas_fixedscale_old_api2/expected_atlas_fixedscale_old_api2_mask.png
  41. BIN tests/testdata/control_images/expected_atlas_hiding1/expected_atlas_hiding1_mask.png
  42. BIN tests/testdata/control_images/expected_atlas_hiding2/expected_atlas_hiding2_mask.png
  43. BIN ...estdata/control_images/expected_atlas_predefinedscales1/expected_atlas_predefinedscales1_mask.png
  44. BIN ...estdata/control_images/expected_atlas_predefinedscales2/expected_atlas_predefinedscales2_mask.png
  45. BIN tests/testdata/control_images/expected_atlas_sorting1/expected_atlas_sorting1_mask.png
  46. BIN tests/testdata/control_images/expected_atlas_sorting2/expected_atlas_sorting2_mask.png
  47. BIN tests/testdata/control_images/expected_atlas_two_maps1/expected_atlas_two_maps1_mask.png
  48. BIN tests/testdata/control_images/expected_atlas_two_maps2/expected_atlas_two_maps2_mask.png
  49. BIN .../expected_composerattributetable_columnwidth/expected_composerattributetable_columnwidth_mask.png
  50. BIN ...ages/expected_composerattributetable_drawempty/expected_composerattributetable_drawempty_mask.png
  51. BIN .../expected_composerattributetable_headersonly/expected_composerattributetable_headersonly_mask.png
  52. BIN ...rol_images/expected_composerattributetable_render/expected_composerattributetable_render_mask.png
  53. BIN .../expected_composerattributetable_showmessage/expected_composerattributetable_showmessage_mask.png
  54. BIN ...xpected_composermap_exteriorticks_annotated/expected_composermap_exteriorticks_annotated_mask.png
  55. BIN ...ected_composermap_exteriorticks_annotated2/expected_composermap_exteriorticks_annotated2_mask.png
  56. BIN ...images/expected_composermap_filteredannotations/expected_composermap_filteredannotations_mask.png
  57. BIN tests/testdata/control_images/expected_composermap_grid/expected_composermap_grid_mask.png
  58. BIN ...map_interiorexteriorticks_annotated/expected_composermap_interiorexteriorticks_annotated_mask.png
  59. BIN ...p_interiorexteriorticks_annotated2/expected_composermap_interiorexteriorticks_annotated2_mask.png
  60. BIN ...xpected_composermap_interiorticks_annotated/expected_composermap_interiorticks_annotated_mask.png
  61. BIN ...ected_composermap_interiorticks_annotated2/expected_composermap_interiorticks_annotated2_mask.png
  62. BIN ...ages/expected_composermap_lineborder_annotated/expected_composermap_lineborder_annotated_mask.png
  63. BIN ...es/expected_composermap_lineborder_annotated2/expected_composermap_lineborder_annotated2_mask.png
  64. BIN ...l_images/expected_composermap_rotatedannotations/expected_composermap_rotatedannotations_mask.png
  65. BIN ...ted_composermap_verticaldescending_inside/expected_composermap_verticaldescending_inside_mask.png
  66. BIN ...d_composermap_verticaldescending_outside/expected_composermap_verticaldescending_outside_mask.png
  67. BIN .../testdata/control_images/expected_composerrotation_label/expected_composerrotation_label_mask.png
  68. BIN ...a/control_images/expected_composerscalebar_doublebox/expected_composerscalebar_doublebox_mask.png
  69. BIN ...tdata/control_images/expected_composerscalebar_numeric/expected_composerscalebar_numeric_mask.png
  70. BIN ...a/control_images/expected_composerscalebar_singlebox/expected_composerscalebar_singlebox_mask.png
  71. BIN ...ages/expected_composerscalebar_singlebox_alpha/expected_composerscalebar_singlebox_alpha_mask.png
  72. BIN tests/testdata/control_images/expected_composerscalebar_tick/expected_composerscalebar_tick_mask.png
  73. BIN ...a/control_images/expected_composerutils_drawtext_pos/expected_composerutils_drawtext_pos_mask.png
  74. BIN ...es/expected_composerutils_drawtext_posnocolor/expected_composerutils_drawtext_posnocolor_mask.png
  75. BIN ...control_images/expected_composerutils_drawtext_rect/expected_composerutils_drawtext_rect_mask.png
  76. BIN ...ages/expected_composerutils_drawtext_rectalign/expected_composerutils_drawtext_rectalign_mask.png
  77. BIN ...images/expected_composerutils_drawtext_rectflag/expected_composerutils_drawtext_rectflag_mask.png
  78. BIN .../expected_composerutils_drawtext_rectnocolor/expected_composerutils_drawtext_rectnocolor_mask.png
  79. BIN tests/testdata/control_images/expected_geometry_bufferCheck/expected_geometry_bufferCheck_mask.png
  80. BIN ...ata/control_images/expected_geometry_differenceCheck2/expected_geometry_differenceCheck2_mask.png
  81. BIN tests/testdata/control_images/expected_imageop_bcnochange/expected_imageop_bcnochange_mask.png
  82. BIN tests/testdata/control_images/expected_imageop_colorizefull/expected_imageop_colorizefull_mask.png
  83. BIN ...estdata/control_images/expected_imageop_colorizepartial/expected_imageop_colorizepartial_mask.png
  84. BIN .../testdata/control_images/expected_imageop_decreasebright/expected_imageop_decreasebright_mask.png
  85. BIN ...tdata/control_images/expected_imageop_decreasecontrast/expected_imageop_decreasecontrast_mask.png
  86. BIN tests/testdata/control_images/expected_imageop_decreasesat/expected_imageop_decreasesat_mask.png
  87. BIN tests/testdata/control_images/expected_imageop_dt_spread/expected_imageop_dt_spread_mask.png
  88. BIN tests/testdata/control_images/expected_imageop_fliphoz/expected_imageop_fliphoz_mask.png
  89. BIN tests/testdata/control_images/expected_imageop_flipvert/expected_imageop_flipvert_mask.png
  90. BIN tests/testdata/control_images/expected_imageop_gaussianblur/expected_imageop_gaussianblur_mask.png
  91. BIN ...a/control_images/expected_imageop_gaussianblur_small/expected_imageop_gaussianblur_small_mask.png
  92. BIN tests/testdata/control_images/expected_imageop_grayaverage/expected_imageop_grayaverage_mask.png
  93. BIN tests/testdata/control_images/expected_imageop_graylightness/expected_imageop_graylightness_mask.png
  94. BIN .../testdata/control_images/expected_imageop_grayluminosity/expected_imageop_grayluminosity_mask.png
  95. BIN .../testdata/control_images/expected_imageop_increasebright/expected_imageop_increasebright_mask.png
  96. BIN ...tdata/control_images/expected_imageop_increasecontrast/expected_imageop_increasecontrast_mask.png
  97. BIN tests/testdata/control_images/expected_imageop_increasesat/expected_imageop_increasesat_mask.png
  98. BIN tests/testdata/control_images/expected_imageop_nochange/expected_imageop_nochange_mask.png
  99. BIN ...estdata/control_images/expected_imageop_opacitydecrease/expected_imageop_opacitydecrease_mask.png
  100. BIN ...estdata/control_images/expected_imageop_opacityincrease/expected_imageop_opacityincrease_mask.png
  101. BIN ...estdata/control_images/expected_imageop_opacitynochange/expected_imageop_opacitynochange_mask.png
  102. BIN tests/testdata/control_images/expected_imageop_overlaycolor/expected_imageop_overlaycolor_mask.png
  103. BIN tests/testdata/control_images/expected_imageop_satnochange/expected_imageop_satnochange_mask.png
  104. BIN tests/testdata/control_images/expected_imageop_smallimage/expected_imageop_smallimage_mask.png
  105. BIN tests/testdata/control_images/expected_imageop_stackblur/expected_imageop_stackblur_mask.png
  106. BIN ...control_images/expected_imageop_stackblur_alphaonly/expected_imageop_stackblur_alphaonly_mask.png
  107. BIN tests/testdata/control_images/expected_legend_three_columns/expected_legend_three_columns_mask.png
  108. BIN tests/testdata/control_images/expected_painteffect_blur/expected_painteffect_blur_mask.png
  109. BIN .../testdata/control_images/expected_painteffect_drawsource/expected_painteffect_drawsource_mask.png
  110. BIN tests/testdata/control_images/expected_painteffect_outerglow/expected_painteffect_outerglow_mask.png
  111. BIN tests/testdata/control_images/expected_painteffect_stack/expected_painteffect_stack_mask.png
  112. BIN ...control_images/expected_pal_canvas/sp_partials_labels_enabled/sp_partials_labels_enabled_mask.png
  113. BIN ...trol_images/expected_pal_canvas_line/sp_curved_placement_above/sp_curved_placement_above_mask.png
  114. BIN ...trol_images/expected_pal_canvas_line/sp_curved_placement_below/sp_curved_placement_below_mask.png
  115. BIN ...ol_images/expected_pal_canvas_line/sp_curved_placement_online/sp_curved_placement_online_mask.png
  116. BIN ...s_line/sp_line_placement_above_line_orientation/sp_line_placement_above_line_orientation_mask.png
  117. BIN ...vas_line/sp_line_placement_above_map_orientation/sp_line_placement_above_map_orientation_mask.png
  118. BIN ...s_line/sp_line_placement_below_line_orientation/sp_line_placement_below_line_orientation_mask.png
  119. BIN ...vas_line/sp_line_placement_below_map_orientation/sp_line_placement_below_map_orientation_mask.png
  120. BIN ...ontrol_images/expected_pal_canvas_line/sp_line_placement_online/sp_line_placement_online_mask.png
  121. BIN ...ages/expected_pal_composer/sp_img_partials_labels_enabled/sp_img_partials_labels_enabled_mask.png
  122. BIN ...ages/expected_pal_composer/sp_pdf_partials_labels_enabled/sp_pdf_partials_labels_enabled_mask.png
  123. BIN ...ages/expected_pal_composer/sp_svg_partials_labels_enabled/sp_svg_partials_labels_enabled_mask.png
  124. BIN tests/testdata/control_images/expected_rgbwcmyk01_YeGeo.jp2/expected_rgbwcmyk01_YeGeo.jp2_mask.png
  125. BIN ...rol_images/maprotation/expected_lines-parallel-label+45/expected_lines-parallel-label+45_mask.png
@@ -1,67 +1,66 @@
*.pyc
.DS_Store
Thumb.db
desktop.ini
*.*~
*~
*.aux
*.diff
*.orig
*.log*
*.orig
*.out
*.prepare
debian/*.debhelper
debian/*.substvars
Makefile
*.pyc
*.sortinc
*.tex
*.toc
*~
*-stamp
.*.swp
.DS_Store
.idea
.kdev4/
.project
.pydevproject
/CMakeLists.txt.user
/CMakeLists.txt.user.*
/python/plugins/sextante/about/ui_aboutdialogbase.py
/python/plugins/sextante/resources_rc.py
api_doc
build*
debian/*.debhelper
debian/*.substvars
desktop.ini
doc/CODING.tex
doc/INSTALL.tex
i18n/*.qm
Makefile
ms-windows/*.exe*
ms-windows/Installer-Files/postinstall.bat
ms-windows/Installer-Files/preremove.bat
ms-windows/osgeo4w/packages/
ms-windows/osgeo4w/unpacked/
ms-windows/*Setup.exe
ms-windows/osgeo4w/nsis/
ms-windows/osgeo4w/untgz/
scripts/astyle
qtcreator-build/
ms-windows/nsis/
ms-windows/osgeo4w/addons/
ms-windows/packages/
ms-windows/osgeo4w/binary-*
ms-windows/osgeo4w/nsis/
ms-windows/osgeo4w/packages-x86/
ms-windows/osgeo4w/packages-x86_64/
ms-windows/osgeo4w/unpacked/
ms-windows/osgeo4w/untgz/
ms-windows/packages/
ms-windows/progs/
ms-windows/untgz/
qgis.kdev4
qgis.supp
qgis-test.ctest
qtcreator-build/
scripts/astyle.exe
# vim temporary files
.*.swp
*.aux
*.out
*.tex
*.toc
*.sortinc
doc/CODING.tex
doc/INSTALL.tex
scripts/Debug
scripts/qgisstyle*
scripts/RelWithDebInfo
/CMakeLists.txt.user
/CMakeLists.txt.user.*
qgis-test.ctest
i18n/*.qm
.project
.pydevproject
.idea
/python/plugins/sextante/resources_rc.py
/python/plugins/sextante/about/ui_aboutdialogbase.py
scripts/qgisstyle
.kdev4/
qgis.kdev4
qgis.supp
src/core/qgscontexthelp_texts.cpp
src/core/qgsexpression_texts.cpp
tests/testdata/checker360by180.asc.aux.xml
tests/testdata/grass/wgs84/test/.gislock
tests/testdata/grass/wgs84/test6/.gislock
tests/testdata/grass/wgs84/test7/.gislock
tests/testdata/raster/band1_byte_noct_epsg4326.tif.aux.xml
tests/testdata/raster/band1_float32_noct_epsg4326.tif.aux.xml
tests/testdata/raster/band1_int16_noct_epsg4326.tif.aux.xml
tests/testdata/raster/band3_float32_noct_epsg4326.tif.aux.xml
tests/testdata/raster/band3_int16_noct_epsg4326.tif.aux.xml
tests/testdata/checker360by180.asc.aux.xml
tests/testdata/grass/wgs84/test/.gislock
tests/testdata/grass/wgs84/test6/.gislock
tests/testdata/grass/wgs84/test7/.gislock
Thumb.db
@@ -80,7 +80,7 @@ def updateMask(control_image_path, rendered_image_path, mask_image_path):
#read current mask, if it exist
mask_image = imageFromPath( mask_image_path )
if mask_image.isNull():
print 'Mask image does not exist, creating'
print 'Mask image does not exist, creating {}'.format( mask_image_path )
mask_image = QImage( control_image.width(), control_image.height(), QImage.Format_ARGB32 )
mask_image.fill( QColor(0,0,0) )

@@ -113,7 +113,9 @@ def updateMask(control_image_path, rendered_image_path, mask_image_path):
if mismatch_count:
#update mask
mask_image.save( mask_image_path, "png" )
print 'Updated {} pixels'.format( mismatch_count )
print 'Updated {} pixels in {}'.format( mismatch_count, mask_image_path )
else:
print 'No mismatches in {}'.format( mask_image_path )

parser = argparse.ArgumentParser() # OptionParser("usage: %prog control_image rendered_image mask_image")
parser.add_argument('control_image')
@@ -42,7 +42,25 @@ bool QgsFontUtils::fontFamilyOnSystem( const QString& family )
bool QgsFontUtils::fontFamilyHasStyle( const QString& family, const QString& style )
{
QFontDatabase fontDB;
return ( fontFamilyOnSystem( family ) && fontDB.styles( family ).contains( style ) );
if ( !fontFamilyOnSystem( family ) )
return false;

if ( fontDB.styles( family ).contains( style ) )
return true;

#ifdef Q_OS_WIN
QString modified( style );
if ( style == "Roman" )
modified = "Normal";
if ( style == "Oblique" )
modified = "Italic";
if ( style == "Bold Oblique" )
modified = "Bold Italic";
if ( fontDB.styles( family ).contains( modified ) )
return true;
#endif

return false;
}

bool QgsFontUtils::fontFamilyMatchOnSystem( const QString& family, QString* chosen, bool* match )
@@ -255,9 +255,14 @@ bool QgsRenderChecker::compareImages( QString theTestName,
}
if ( ! theRenderedImageFile.isEmpty() )
{
#ifndef Q_OS_WIN
mRenderedImageFile = theRenderedImageFile;
#else
mRenderedImageFile = theRenderedImageFile.replace( "\\", "/" );
#endif
}
else if ( mRenderedImageFile.isEmpty() )

if ( mRenderedImageFile.isEmpty() )
{
qDebug( "QgsRenderChecker::runTest failed - Rendered Image File not set." );
mReport = "<table>"
@@ -266,6 +271,7 @@ bool QgsRenderChecker::compareImages( QString theTestName,
"Image File not set.</td></tr></table>\n";
return false;
}

//
// Load /create the images
//
@@ -308,16 +314,16 @@ bool QgsRenderChecker::compareImages( QString theTestName,
mReport = QString( "<script src=\"file://%1/../renderchecker.js\"></script>\n" ).arg( TEST_DATA_DIR );
mReport += "<table>";
mReport += "<tr><td colspan=2>";
mReport += QString( "Test image and result image for %1<br>"
mReport += QString( "<tr><td colspan=2>"
"Test image and result image for %1<br>"
"Expected size: %2 w x %3 h (%4 pixels)<br>"
"Actual size: %5 w x %6 h (%7 pixels)" )
"Actual size: %5 w x %6 h (%7 pixels)"
"</td></tr>" )
.arg( theTestName )
.arg( myExpectedImage.width() ).arg( myExpectedImage.height() ).arg( mMatchTarget )
.arg( myResultImage.width() ).arg( myResultImage.height() ).arg( myPixelCount );

mReport += "</td></tr>";
mReport += "<tr><td colspan=2>\n";
mReport += QString( "Expected Duration : <= %1 (0 indicates not specified)<br>"
mReport += QString( "<tr><td colspan=2>\n"
"Expected Duration : <= %1 (0 indicates not specified)<br>"
"Actual Duration : %2 ms<br></td></tr>" )
.arg( mElapsedTimeTarget )
.arg( mElapsedTime );
@@ -368,7 +374,7 @@ bool QgsRenderChecker::compareImages( QString theTestName,

if ( mMatchTarget != myPixelCount )
{
qDebug( "Test image and result image for %s are different - FAILING!", theTestName.toLocal8Bit().constData() );
qDebug( "Test image and result image for %s are different dimensions - FAILING!", theTestName.toLocal8Bit().constData() );
mReport += "<tr><td colspan=3>";
mReport += "<font color=red>Expected image and result image for " + theTestName + " are different dimensions - FAILING!</font>";
mReport += "</td></tr>";
@@ -439,40 +445,14 @@ bool QgsRenderChecker::compareImages( QString theTestName,
//
// Send match result to report
//
mReport += "<tr><td colspan=3>" +
QString::number( mMismatchCount ) + "/" +
QString::number( mMatchTarget ) +
" pixels mismatched (allowed threshold: " +
QString::number( theMismatchCount ) +
", allowed color component tolerance: " +
QString::number( mColorTolerance ) + ")";
mReport += "</td></tr>";
mReport += QString( "<tr><td colspan=3>%1/%2 pixels mismatched (allowed threshold: %3, allowed color component tolerance: %4)</td></tr>" )
.arg( mMismatchCount ).arg( mMatchTarget ).arg( theMismatchCount ).arg( mColorTolerance );

//
// And send it to CDash
//
emitDashMessage( "Mismatch Count", QgsDartMeasurement::Integer, QString( "%1/%2" ).arg( mMismatchCount ).arg( mMatchTarget ) );

bool myAnomalyMatchFlag = isKnownAnomaly( myDiffImageFile );

if ( myAnomalyMatchFlag )
{
mReport += "<tr><td colspan=3>"
"Difference image matched a known anomaly - passing test! "
"</td></tr>";
return true;
}
else
{
mReport += "<tr><td colspan=3>"
"</td></tr>";
emitDashMessage( "No Anomalies Match", QgsDartMeasurement::Text, "Difference image did not match any known anomaly."
" If you feel the difference image should be considered an anomaly "
"you can do something like this\n"
"cp " + myDiffImageFile + " ../tests/testdata/control_images/" + theTestName +
"/<imagename>.{wld,png}" );
}

if ( mMismatchCount <= theMismatchCount )
{
mReport += "<tr><td colspan = 3>\n";
@@ -494,12 +474,27 @@ bool QgsRenderChecker::compareImages( QString theTestName,
return true;
}
}
else

bool myAnomalyMatchFlag = isKnownAnomaly( myDiffImageFile );
if ( myAnomalyMatchFlag )
{
mReport += "<tr><td colspan = 3>\n";
mReport += "<font color=red>Test image and result image for " + theTestName + " are mismatched</font><br>";
mReport += "</td></tr>";
mReport += myImagesString;
return false;
mReport += "<tr><td colspan=3>"
"Difference image matched a known anomaly - passing test! "
"</td></tr>";
return true;
}

mReport += "<tr><td colspan=3></td></tr>";
emitDashMessage( "Image mismatch", QgsDartMeasurement::Text, "Difference image did not match any known anomaly or mask."
" If you feel the difference image should be considered an anomaly "
"you can do something like this\n"
"cp '" + myDiffImageFile + "' " + controlImagePath() + mControlName +
"/\nIf it should be included in the mask run\n"
"scripts/generate_test_mask_image.py '" + mExpectedImageFile + "' '" + mRenderedImageFile + "'\n" );

mReport += "<tr><td colspan = 3>\n";
mReport += "<font color=red>Test image and result image for " + theTestName + " are mismatched</font><br>";
mReport += "</td></tr>";
mReport += myImagesString;
return false;
}
@@ -66,9 +66,9 @@ class CORE_EXPORT QgsRenderChecker
/** Prefix where the control images are kept.
* This will be appended to controlImagePath
*/
void setControlPathPrefix( const QString &theName ) { mControlPathPrefix = theName + QDir::separator(); }
void setControlPathPrefix( const QString &theName ) { mControlPathPrefix = theName + "/"; }

void setControlPathSuffix( const QString& theName ) { mControlPathSuffix = theName + QDir::separator(); }
void setControlPathSuffix( const QString& theName ) { mControlPathSuffix = theName + "/"; }

/** Get an md5 hash that uniquely identifies an image */
QString imageToHash( QString theImageFile );
@@ -129,7 +129,7 @@ class CORE_EXPORT QgsRenderChecker
*/
bool isKnownAnomaly( QString theDiffImageFile );

/**Draws a checkboard pattern for image backgrounds, so that transparency is visible
/** Draws a checkboard pattern for image backgrounds, so that transparency is visible
* without requiring a transparent background for the image
*/
static void drawBackground( QImage* image );
@@ -20,6 +20,7 @@

#include <QtGlobal>
#include <QFile>
#include <QFileInfo>
#include <QDataStream>
#include <QTextStream>
#include <QFileSystemWatcher>
@@ -840,7 +841,6 @@ QgsDelimitedTextFile::Status QgsDelimitedTextFile::parseQuoted( QString &buffer,

bool QgsDelimitedTextFile::isValid()
{

return mDefinitionValid && QFile::exists( mFileName );
return mDefinitionValid && QFile::exists( mFileName ) && QFileInfo( mFileName ).size() > 0;
}

@@ -4060,6 +4060,7 @@ void QgsSpatiaLiteProvider::closeDb()
if ( handle )
{
QgsSqliteHandle::closeDb( handle );
handle = 0;
}
}

@@ -63,7 +63,7 @@ MACRO (ADD_QGIS_TEST testname testsrc)
${QT_QTCORE_LIBRARY}
${QT_QTTEST_LIBRARY}
qgis_analysis)
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname})
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname} -maxwarnings 10000)
#SET_TARGET_PROPERTIES(qgis_${testname} PROPERTIES
# INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${QGIS_LIB_DIR}
# INSTALL_RPATH_USE_LINK_PATH true )
@@ -82,7 +82,7 @@ MACRO (ADD_QGIS_TEST testname testsrc)
IF (APPLE)
TARGET_LINK_LIBRARIES(qgis_${testname} ${APP_SERVICES_LIBRARY} )
ENDIF(APPLE)
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname})
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname} -maxwarnings 10000)
#SET_TARGET_PROPERTIES(qgis_${testname} PROPERTIES
# INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${QGIS_LIB_DIR}
# INSTALL_RPATH_USE_LINK_PATH true )
@@ -68,7 +68,7 @@ MACRO (ADD_QGIS_TEST testname testsrc)
${GEOS_LIBRARY}
${GDAL_LIBRARY}
qgis_core)
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname})
ADD_TEST(qgis_${testname} ${CMAKE_CURRENT_BINARY_DIR}/../../../output/bin/qgis_${testname} -maxwarnings 10000)
#SET_TARGET_PROPERTIES(qgis_${testname} PROPERTIES
# INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${QGIS_LIB_DIR}
# INSTALL_RPATH_USE_LINK_PATH true )

0 comments on commit 5b54e26

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