You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
260 B
15 lines
260 B
|
13 years ago
|
"""
|
||
|
|
# Tests of the utils itercompat library.
|
||
|
|
|
||
|
|
>>> from django.utils.itercompat import sorted as compat_sorted
|
||
|
|
|
||
|
|
# Check the replacement version of sorted
|
||
|
|
>>> x = [5,1,4,2,3]
|
||
|
|
>>> y = compat_sorted(x)
|
||
|
|
>>> print y
|
||
|
|
[1, 2, 3, 4, 5]
|
||
|
|
|
||
|
|
>>> print x
|
||
|
|
[5, 1, 4, 2, 3]
|
||
|
|
|
||
|
|
"""
|