summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Sassoulas <pierre.sassoulas@gmail.com>2021-06-23 13:54:33 +0200
committerPierre Sassoulas <pierre.sassoulas@gmail.com>2021-06-29 19:40:23 +0200
commitdf5c3fcf2557bda0b8202ddd2aeb359bcbd0d994 (patch)
treec5442e5f25cde843774f56cad9d853b54b49be90
parenteeb6eea190a3e20e98f3d874b5374a81389a9a10 (diff)
downloadpylint-git-df5c3fcf2557bda0b8202ddd2aeb359bcbd0d994.tar.gz
Add a regression test following issue #4610
-rw-r--r--tests/functional/t/typedDict.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/functional/t/typedDict.py b/tests/functional/t/typedDict.py
index 912a4eae6..0f908216e 100644
--- a/tests/functional/t/typedDict.py
+++ b/tests/functional/t/typedDict.py
@@ -1,5 +1,5 @@
"""Test typing.TypedDict"""
-# pylint: disable=invalid-name,missing-class-docstring
+# pylint: disable=invalid-name,missing-class-docstring,pointless-statement
import typing
from typing import TypedDict
@@ -7,12 +7,19 @@ from typing import TypedDict
class CustomTD(TypedDict):
var: int
+
class CustomTD2(typing.TypedDict, total=False):
var2: str
+
class CustomTD3(CustomTD2):
var3: int
+
CustomTD4 = TypedDict("CustomTD4", var4=bool)
CustomTD5 = TypedDict("CustomTD5", {"var5": bool})
+
+my_dict = CustomTD(var=1)
+my_dict["var"]
+my_dict["var"] = 2