TypeScript/tests/baselines/reference/moduleAugmentationWithNonExistentNamedImport.types
Sheetal Nandi 9c60d5a4d3
Dont look for properties of Object and Function type when looking to resolve named import from module with export= (#37964)
* Add tests

* Dont look at object or function type when looking for members of `export=` type to be resolved by named imports
Fixes #37165

* Create separate cache when skipping function and object property augmentation

* Lookup in both cache if not skipObjectFunctionPropertyAugment
2020-11-03 12:22:30 -08:00

31 lines
427 B
Plaintext

=== tests/cases/compiler/foo.d.ts ===
export = Foo;
>Foo : typeof Foo
export as namespace Foo;
>Foo : typeof Foo
declare namespace Foo {
>Foo : typeof Foo
function foo();
>foo : () => any
}
declare global {
>global : any
namespace Bar { }
}
=== tests/cases/compiler/bar.d.ts ===
import { Bar } from './foo';
>Bar : any
export = Bar;
>Bar : any
export as namespace Bar;
>Bar : any