summaryrefslogtreecommitdiff
path: root/testtools/matchers/_basic.py
diff options
context:
space:
mode:
authorJonathan Lange <jml@mumak.net>2015-12-21 18:38:41 +0000
committerJonathan Lange <jml@mumak.net>2015-12-21 18:43:36 +0000
commitdc3d75cbaef1746cf59b401549712960bb2be3e2 (patch)
tree88ffd31ccb9ba74a2b2ebd3e772334232c95d0fd /testtools/matchers/_basic.py
parent7e50cb22b87d9f024a97e1c74a2db5f2d7744091 (diff)
downloadtesttools-dc3d75cbaef1746cf59b401549712960bb2be3e2.tar.gz
Put expected on the right for binary mismatch
Diffstat (limited to 'testtools/matchers/_basic.py')
-rw-r--r--testtools/matchers/_basic.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/testtools/matchers/_basic.py b/testtools/matchers/_basic.py
index 2d9f143..4780a08 100644
--- a/testtools/matchers/_basic.py
+++ b/testtools/matchers/_basic.py
@@ -57,7 +57,7 @@ class _BinaryComparison(object):
def match(self, other):
if self.comparator(other, self.expected):
return None
- return _BinaryMismatch(self.expected, self.mismatch_string, other)
+ return _BinaryMismatch(other, self.mismatch_string, self.expected)
def comparator(self, expected, other):
raise NotImplementedError(self.comparator)
@@ -111,14 +111,14 @@ class LessThan(_BinaryComparison):
"""Matches if the item is less than the matchers reference object."""
comparator = operator.__lt__
- mismatch_string = 'is not >'
+ mismatch_string = '>='
class GreaterThan(_BinaryComparison):
"""Matches if the item is greater than the matchers reference object."""
comparator = operator.__gt__
- mismatch_string = 'is not <'
+ mismatch_string = '<='
class SameMembers(Matcher):