diff options
author | Raymond Hettinger <python@rcn.com> | 2003-12-17 20:43:33 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2003-12-17 20:43:33 (GMT) |
commit | 64958a15d7c03efdc3d2eddf247666e18d1fd910 (patch) | |
tree | bc135ae082f8635fa858b81f52f141d7ffbd4c78 /Lib/test/test_set.py | |
parent | df38ea9c29a431602704c6bd45ca7417225a61c4 (diff) | |
download | cpython-64958a15d7c03efdc3d2eddf247666e18d1fd910.zip cpython-64958a15d7c03efdc3d2eddf247666e18d1fd910.tar.gz cpython-64958a15d7c03efdc3d2eddf247666e18d1fd910.tar.bz2 |
Guido grants a Christmas wish:
sorted() becomes a regular function instead of a classmethod.
Diffstat (limited to 'Lib/test/test_set.py')
-rw-r--r-- | Lib/test/test_set.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/test/test_set.py b/Lib/test/test_set.py index f3cdc17..5d37169 100644 --- a/Lib/test/test_set.py +++ b/Lib/test/test_set.py @@ -22,8 +22,8 @@ class TestJointOps(unittest.TestCase): self.d = dict.fromkeys(word) def test_uniquification(self): - actual = list.sorted(self.s) - expected = list.sorted(self.d) + actual = sorted(self.s) + expected = sorted(self.d) self.assertEqual(actual, expected) self.assertRaises(PassThru, self.thetype, check_pass_thru()) self.assertRaises(TypeError, self.thetype, [[]]) @@ -1241,7 +1241,7 @@ class TestVariousIteratorArgs(unittest.TestCase): for cons in (set, frozenset): for s in ("123", "", range(1000), ('do', 1.2), xrange(2000,2200,5)): for g in (G, I, Ig, S, L, R): - self.assertEqual(list.sorted(cons(g(s))), list.sorted(g(s))) + self.assertEqual(sorted(cons(g(s))), sorted(g(s))) self.assertRaises(TypeError, cons , X(s)) self.assertRaises(TypeError, cons , N(s)) self.assertRaises(ZeroDivisionError, cons , E(s)) @@ -1253,7 +1253,7 @@ class TestVariousIteratorArgs(unittest.TestCase): for g in (G, I, Ig, L, R): expected = meth(data) actual = meth(G(data)) - self.assertEqual(list.sorted(actual), list.sorted(expected)) + self.assertEqual(sorted(actual), sorted(expected)) self.assertRaises(TypeError, meth, X(s)) self.assertRaises(TypeError, meth, N(s)) self.assertRaises(ZeroDivisionError, meth, E(s)) @@ -1267,7 +1267,7 @@ class TestVariousIteratorArgs(unittest.TestCase): t = s.copy() getattr(s, methname)(list(g(data))) getattr(t, methname)(g(data)) - self.assertEqual(list.sorted(s), list.sorted(t)) + self.assertEqual(sorted(s), sorted(t)) self.assertRaises(TypeError, getattr(set('january'), methname), X(data)) self.assertRaises(TypeError, getattr(set('january'), methname), N(data)) |