Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Reset subset string after testing
Wfs test fails otherwise.
  • Loading branch information
m-kuhn committed Jun 4, 2018
1 parent 6dd26bb commit 5d3a4cd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/src/python/providertestbase.py
Expand Up @@ -421,6 +421,7 @@ def testEmpty(self):
self.assertEqual(self.source.hasFeatures(), QgsFeatureSource.FeaturesAvailable)

if self.source.supportsSubsetString():
backup = self.source.subsetString()
# Add a subset string and test feature count
subset = self.getSubsetString()
self.source.setSubsetString(subset)
Expand All @@ -432,6 +433,7 @@ def testEmpty(self):
self.assertEqual(self.source.hasFeatures(), QgsFeatureSource.NoFeaturesAvailable)
self.source.setSubsetString(None)
self.assertFalse(self.source.empty())
self.source.setSubsetString(backup)

# If the provider supports tests on editable layers
if getattr(self, 'getEditableLayer', None):
Expand Down

0 comments on commit 5d3a4cd

Please sign in to comment.