Skip to content

Commit e45ef52

Browse files
committed
Add test case for when new syntax feature flag is not enabled
1 parent 440ca82 commit e45ef52

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

test-data/unit/check-typeddict.test

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3707,6 +3707,12 @@ reveal_type(x) # N: Revealed type is "TypedDict({'a': builtins.int, 'b': builti
37073707
[builtins fixtures/dict.pyi]
37083708
[typing fixtures/typing-full.pyi]
37093709

3710+
[case testTypedDictInlinePEP764NotEnabled]
3711+
from typing import TypedDict
3712+
x: TypedDict[{"a": int}] # E: PEP 764 inline TypedDict is experimental, must be enabled with --enable-incomplete-feature=NewInlineTypedDict
3713+
[builtins fixtures/dict.pyi]
3714+
[typing fixtures/typing-typeddict.pyi]
3715+
37103716
[case testTypedDictInlinePEP764OldStyleAlias]
37113717
# flags: --enable-incomplete-feature=NewInlineTypedDict
37123718
from typing import TypedDict

0 commit comments

Comments
 (0)