Skip to content

Commit

Permalink
Add test for deep, generic type alias
Browse files Browse the repository at this point in the history
  • Loading branch information
dmoisset committed Sep 1, 2017
1 parent 7302599 commit df0d5cf
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test-data/unit/stubgen.test
Original file line number Diff line number Diff line change
Expand Up @@ -771,6 +771,18 @@ alias = Dict[str, List[str]]
[out]
alias = Dict[str, List[str]]

[case testDeepGenericTypeAliasPreserved]
from typing import TypeVar

T = TypeVar('T')
alias = Union[T, List[T]]

[out]
from typing import TypeVar

T = TypeVar('T')
alias = Union[T, List[T]]

[case testEllipsisAliasPreserved]

alias = Tuple[int, ...]
Expand Down

0 comments on commit df0d5cf

Please sign in to comment.