void () { runWithLanguageLevel( LanguageLevel.getLatest(), () -> doTestByText(""" from typing import TypedDict class Movie(TypedDict): name: str year: int m1: Movie = dict(name='Alien', year=1979) m2 = Movie(name='Garden State', year=2004) def foo(p: int): pass foo(m2["year"]) foo(<warning descr="Expected type 'int', got 'str' instead">m2["name"]</warning>) foo(<warning descr="Expected type 'int', got 'str' instead">m1["name"]</warning>)""") ); }