summaryrefslogtreecommitdiff
path: root/tests/functional/t/typealias_naming_style_rgx.py
blob: bc43b930d5e0a5dfc8854c71db20d3853edec054 (plain)
1
2
3
4
5
6
7
8
9
10
"""Test cases for invalid-name for TypeAlias and related classes with non-default settings."""
from typing import TypeAlias, Union

# Valid
TypeAliasShouldBeLikeThis: TypeAlias = int
_TypeAliasShouldBeLikeThis = Union[str, int]

# Invalid
TypeAliasShouldntBeLikeThis: TypeAlias = int  # [invalid-name]
_TypeAliasShouldntBeLikeThis = Union[str, int]  # [invalid-name]