summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDaniël van Noord <13665637+DanielNoord@users.noreply.github.com>2023-03-23 22:53:01 +0100
committerDaniël van Noord <13665637+DanielNoord@users.noreply.github.com>2023-03-23 23:48:41 +0100
commitebf1952eb5b4bac46751d91181a62bea4bd6599f (patch)
treecb0c911b3cdc70cd82610ab716bb12ccdc1f522b /tests
parentb9c1ab3cd5323f5cb305a12c9e105102e4200ead (diff)
downloadpylint-git-ebf1952eb5b4bac46751d91181a62bea4bd6599f.tar.gz
Don't consider ``Union`` to always be a type alias (#8489)
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com> (cherry picked from commit 07127ee75f3456920ff5117cdbaf8697744b6cfc)
Diffstat (limited to 'tests')
-rw-r--r--tests/functional/t/typealias_naming_style_default.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/functional/t/typealias_naming_style_default.py b/tests/functional/t/typealias_naming_style_default.py
index 45f801521..a2d02c0c6 100644
--- a/tests/functional/t/typealias_naming_style_default.py
+++ b/tests/functional/t/typealias_naming_style_default.py
@@ -21,3 +21,7 @@ BAD_NAME = Union[int, str] # [invalid-name]
_BAD_NAME = Union[int, str] # [invalid-name]
__BAD_NAME = Union[int, str] # [invalid-name]
ANOTHERBADNAME = Union[int, str] # [invalid-name]
+
+# Regression tests
+# This is not a TypeAlias, and thus shouldn't flag the message
+x: Union[str, int] = 42