void () { final PyFile file = (PyFile)myFixture.configureByText(PythonFileType.INSTANCE, "import a\nt = a.b[c]"); myFixture.addFileToProject("a.py", "b = {} # type: dict"); // specify type of `b` so `__getitem__` could be resolved final TypeEvalContext context = TypeEvalContext.codeInsightFallback(myFixture.getProject()); assertEmpty(file.findTopLevelAttribute("t").multiResolveAssignedValue(PyResolveContext.defaultContext(context))); }