Currently, the deviation allowances (allowDeviation and allowPercentDeviation) can only be set to ranges around zero (asserts lower <= 0 <= upper). This should be changed to allow deviations from a given range even when the entire range is above or below zero.
The lower and upper arguments should also work when set to the exact same number:
with self.allowPercentDeviation(lower=-1.0, upper=-1.0): # Allows only 100%
self.assertSubjectSum('C', ['A', 'B']) # deviations but no
# others.
Currently, the deviation allowances (
allowDeviation
andallowPercentDeviation
) can only be set to ranges around zero (assertslower <= 0 <= upper
). This should be changed to allow deviations from a given range even when the entire range is above or below zero.The lower and upper arguments should also work when set to the exact same number: