diff options
Diffstat (limited to 'Lib/unittest/util.py')
-rw-r--r-- | Lib/unittest/util.py | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/Lib/unittest/util.py b/Lib/unittest/util.py index 736c20274d9..ea8a68dc9f3 100644 --- a/Lib/unittest/util.py +++ b/Lib/unittest/util.py @@ -70,15 +70,6 @@ def unorderable_list_difference(expected, actual): # anything left in actual is unexpected return missing, actual -def CmpToKey(mycmp): - 'Convert a cmp= function into a key= function' - class K(object): - def __init__(self, obj, *args): - self.obj = obj - def __lt__(self, other): - return mycmp(self.obj, other.obj) == -1 - return K - def three_way_cmp(x, y): """Return -1 if x < y, 0 if x == y and 1 if x > y""" return (x > y) - (x < y) |