diff --git a/test-data/unit/stubgen.test b/test-data/unit/stubgen.test index 6565e51f9b02..a66126633f53 100644 --- a/test-data/unit/stubgen.test +++ b/test-data/unit/stubgen.test @@ -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, ...]