Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Guido van Rossum committed Oct 21, 2016
1 parent a65e459 commit f9e5003
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions test-data/unit/pythoneval.test
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ def f():
f()
[out]
'x' <class 'collections.abc.Sized'> True
[1] typing.Sequence<+T_co> True
{1: 3} typing.Sequence<+T_co> False
<str_iterator object at 0x...> typing.Iterator<+T_co> True
'x' typing.Iterable<+T_co> True
{} typing.Mapping<~KT, +VT_co> True
{1} typing.AbstractSet<+T_co> True
[1] typing.Sequence True
{1: 3} typing.Sequence False
<str_iterator object at 0x...> typing.Iterator True
'x' typing.Iterable True
{} typing.Mapping True
{1} typing.AbstractSet True

[case testSized]
from typing import Sized
Expand All @@ -51,6 +51,7 @@ print(len(A()))
[case testReversed]
from typing import Reversible
class A(Reversible):
def __iter__(self): return iter('oof')
def __reversed__(self): return iter('foo')
print(list(reversed(range(5))))
print(list(reversed([1,2,3])))
Expand Down

0 comments on commit f9e5003

Please sign in to comment.