Skip to content

Commit 71c8c70

Browse files
committed
Fix test names
1 parent 74f0d89 commit 71c8c70

File tree

1 file changed

+9
-13
lines changed

1 file changed

+9
-13
lines changed

mypyc/test-data/run-lists.test

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ assert not list_in_mixed(object)
466466
assert list_in_mixed(type)
467467

468468
[case testListBuiltFromGenerator]
469-
def test() -> None:
469+
def test_from_gen() -> None:
470470
source_a = ["a", "b", "c"]
471471
a = list(x + "f2" for x in source_a)
472472
assert a == ["af2", "bf2", "cf2"]
@@ -486,12 +486,6 @@ def test() -> None:
486486
f = list("str:" + x for x in source_str)
487487
assert f == ["str:a", "str:b", "str:c", "str:d"]
488488

489-
[case testNextBug]
490-
from typing import List, Optional
491-
492-
def test(x: List[int]) -> None:
493-
res = next((i for i in x), None)
494-
495489
[case testListGetItemWithBorrow]
496490
from typing import List
497491

@@ -540,7 +534,7 @@ def test_sorted() -> None:
540534

541535
[case testIsInstance]
542536
from copysubclass import subc
543-
def test() -> None:
537+
def test_built_in() -> None:
544538
assert isinstance([], list)
545539
assert isinstance([1,2,3], list)
546540
assert isinstance(['a','b'], list)
@@ -555,15 +549,17 @@ def test() -> None:
555549
assert not isinstance(1, list)
556550
assert not isinstance('a', list)
557551

552+
def test_user_defined() -> None:
553+
from userdefinedlist import list
554+
555+
assert isinstance(list(), list)
556+
assert not isinstance([list()], list)
557+
558558
[file copysubclass.py]
559559
from typing import Any
560560
class subc(list[Any]):
561561
pass
562562

563-
[case testUserDefinedList]
563+
[file userdefinedlist.py]
564564
class list:
565565
pass
566-
567-
def test() -> None:
568-
assert isinstance(list(), list)
569-
assert not isinstance([list()], list)

0 commit comments

Comments
 (0)