[Thuban-commits] r2902 - trunk/thuban/test
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Fri Jul 15 14:58:44 CEST 2011
Author: bricks
Date: 2011-07-15 14:58:44 +0200 (Fri, 15 Jul 2011)
New Revision: 2902
Modified:
trunk/thuban/test/test_baserenderer.py
Log:
Skip test_project_raster_broken if gdal is not available
use support.skip_if_no_gdal to skip tests
Modified: trunk/thuban/test/test_baserenderer.py
===================================================================
--- trunk/thuban/test/test_baserenderer.py 2011-07-15 12:52:13 UTC (rev 2901)
+++ trunk/thuban/test/test_baserenderer.py 2011-07-15 12:58:44 UTC (rev 2902)
@@ -101,9 +101,7 @@
def projected_raster_layer(self, layer, srcProj, dstProj, extents,
resolution, dimensions, options):
- if not Thuban.Model.resource.has_gdal_support():
- raise support.SkipTest(Thuban.Model.resource.gdal_support_status)
-
+ support.skip_if_no_gdal()
#print srcProj, dstProj,extents, resolution, dimensions, options
return ProjectRasterFile(layer.GetImageFilename(),
@@ -280,9 +278,7 @@
('EndDrawing',)])
def test_projected_raster_layer(self):
- if not Thuban.Model.resource.has_gdal_support():
- raise support.SkipTest(Thuban.Model.resource.gdal_support_status)
-
+ supported.skip_if_no_gdal()
layer = RasterLayer("raster layer",
os.path.join("..", "Data", "iceland",
"island.tif"))
@@ -358,6 +354,7 @@
If this test passes without IOException, the problem will be solved.
"""
+ support.skip_if_no_gdal()
tiffile= os.path.join("..", "Data", "iceland",
"island.tif")
projection = "+proj=latlong +to_meter=0.017453 +ellps=clrk66"
@@ -373,8 +370,7 @@
t2 = RasterLayer("rast3", tiffile)
def test_projected_raster_decimalcommalocale(self):
- if not Thuban.Model.resource.has_gdal_support():
- raise support.SkipTest(Thuban.Model.resource.gdal_support_status)
+ support.skip_if_no_gdal()
def _do_project_island():
"""Project island.tif and return result."""
@@ -407,9 +403,7 @@
to round-off errors. It simply compares the complete BMP file
returned by gdalwarp.ProjectRasterFile to a BMP file data.
"""
- if not Thuban.Model.resource.has_gdal_support():
- raise support.SkipTest(Thuban.Model.resource.gdal_support_status)
-
+ support.skip_if_no_gdal()
map = Map("TestBaseRenderer")
layer = RasterLayer("raster layer",
More information about the Thuban-commits
mailing list