@@ -75,7 +75,7 @@ class TestZipLayer: public QObject
75
75
void testZipItemAll ();
76
76
// test that styles are loaded from .qml files outside zip files
77
77
void testZipItemVectorTransparency ();
78
- void testGipItemVectorTransparency ();
78
+ void testGZipItemVectorTransparency ();
79
79
void testZipItemRasterTransparency ();
80
80
void testGZipItemRasterTransparency ();
81
81
};
@@ -199,6 +199,8 @@ int TestZipLayer::getLayerTransparency( QString myFileName, QString myProviderKe
199
199
myLayer = getZipLayer ( myFileName, " " );
200
200
if ( myLayer && myLayer->isValid () )
201
201
myTransparency = myLayer->getTransparency ();
202
+ else
203
+ QWARN ( QString ( " Could not open filename %1 using %2 provider" ).arg ( myFileName ).arg ( myProviderKey ).toLocal8Bit ().data () );
202
204
if ( myLayer )
203
205
delete myLayer;
204
206
return myTransparency;
@@ -247,6 +249,9 @@ void TestZipLayer::testPassthruVectorZip()
247
249
248
250
void TestZipLayer::testPassthruVectorGzip ()
249
251
{
252
+ #if GDAL_VERSION_NUM < 1700
253
+ QSKIP ( " This test requires GDAL > 1.7" , SkipSingle );
254
+ #endif
250
255
for ( int i = 1 ; i <= mMaxScanZipSetting ; i++ )
251
256
{
252
257
mSettings .setValue ( " /qgis/scanZipInBrowser" , i );
@@ -313,15 +318,21 @@ void TestZipLayer::testZipItemAll()
313
318
314
319
void TestZipLayer::testZipItemVectorTransparency ()
315
320
{
321
+ #if GDAL_VERSION_NUM < 1800
322
+ QSKIP ( " This test requires GDAL > 1.8" , SkipSingle );
323
+ #endif
316
324
int myTarget = 250 ;
317
325
int myTransparency = getLayerTransparency ( mDataDir + " points2.zip" , " ogr" , 1 );
318
326
QVERIFY2 (( myTransparency == myTarget ), QString ( " Transparency is %1, should be %2" ).arg ( myTransparency ).arg ( myTarget ).toLocal8Bit ().data () );
319
327
myTransparency = getLayerTransparency ( mDataDir + " points2.zip" , " ogr" , 2 );
320
328
QVERIFY2 (( myTransparency == myTarget ), QString ( " Transparency is %1, should be %2" ).arg ( myTransparency ).arg ( myTarget ).toLocal8Bit ().data () );
321
329
}
322
330
323
- void TestZipLayer::testGipItemVectorTransparency ()
331
+ void TestZipLayer::testGZipItemVectorTransparency ()
324
332
{
333
+ #if GDAL_VERSION_NUM < 1700
334
+ QSKIP ( " This test requires GDAL > 1.7" , SkipSingle );
335
+ #endif
325
336
int myTarget = 250 ;
326
337
int myTransparency = getLayerTransparency ( mDataDir + " points3.geojson.gz" , " ogr" , 1 );
327
338
QVERIFY2 (( myTransparency == myTarget ), QString ( " Transparency is %1, should be %2" ).arg ( myTransparency ).arg ( myTarget ).toLocal8Bit ().data () );
0 commit comments