void () { doTest("Derived", """ class Base: @classmethod def instance(cls): return cls() class Derived(Base): pass expr = Derived.instance()"""); doTest("Derived", """ class Base: @classmethod def instance(cls): return cls() class Derived(Base): pass expr = Derived().instance()"""); }