Skip to content

Commit b97e835

Browse files
committed
Re-enable the test on travis with a fix
1 parent a8ce494 commit b97e835

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

tests/src/python/provider_python.py

+5
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,11 @@ def __init__(self, source, request):
6262
self._transform = QgsCoordinateTransform()
6363
if self._request.destinationCrs().isValid() and self._request.destinationCrs() != self._source._provider.crs():
6464
self._transform = QgsCoordinateTransform(self._source._provider.crs(), self._request.destinationCrs(), self._request.transformContext())
65+
try:
66+
self._filter_rect = self.filterRectToSourceCrs(self._transform)
67+
except QgsCsException as e:
68+
self.close()
69+
return
6570
self._filter_rect = self.filterRectToSourceCrs(self._transform)
6671
if not self._filter_rect.isNull():
6772
self._select_rect_geom = QgsGeometry.fromRect(self._filter_rect)

tests/src/python/test_provider_python.py

-1
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,6 @@ def testGetFeaturesNoGeometry(self):
155155
"""
156156
pass
157157

158-
@unittest.skipIf(os.environ.get("TRAVIS", False), "Skipped on Travis")
159158
def testGetFeaturesDestinationCrs(self):
160159
"""Skip this if on travis, passes locally and fails with no reason on Travis"""
161160
super().testGetFeaturesDestinationCrs()

0 commit comments

Comments
 (0)