Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids committed Dec 9, 2019
1 parent 84d6bbe commit 0391c85
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/src/python/test_qgsclassificationmethod.py
Expand Up @@ -74,13 +74,13 @@ def testQgsClassificationLogarithmic_FilterZeroNeg(self):
vl = createMemoryLayer(values)
m = QgsClassificationLogarithmic()

m.setParameterValues({'ZERO_NEG_VALUES_HANDLE': QgsClassificationLogarithmic.NegativeValueHandling.Discard})
m.setParameterValues({'ZERO_NEG_VALUES_HANDLE': QgsClassificationLogarithmic.Discard})
r = m.classes(vl, 'value', 4)
self.assertEqual(len(r), 4)
self.assertEqual(r[0].label(), '1 - 10^1')
self.assertEqual(QgsClassificationMethod.rangesToBreaks(r), [10.0, 100.0, 1000.0, 10000.0])

m.setParameterValues({'ZERO_NEG_VALUES_HANDLE': QgsClassificationLogarithmic.NegativeValueHandling.PrependBreak})
m.setParameterValues({'ZERO_NEG_VALUES_HANDLE': QgsClassificationLogarithmic.PrependBreak})
r = m.classes(vl, 'value', 4)
self.assertEqual(r[0].label(), '-2 - 10^0')
self.assertEqual(QgsClassificationMethod.rangesToBreaks(r), [1.0, 10.0, 100.0, 1000.0, 10000.0])
Expand Down

0 comments on commit 0391c85

Please sign in to comment.