TypeScript/tests/cases/fourslash/server/autoImportProvider4.ts
Andrew Branch ec33814616
Make AutoImportProviderProject work with symlinked monorepos (#39679)
* Hack everything together

* Add test

* Remove realpath from program

* Ensure symlinked directories are directories

* Revert unnecessary change

* Update baselines

* Use host program realpath on AutoImportProviderProject files before program creation

* Which fixes hasRoots() too

* Apply suggestions from code review

Co-authored-by: Sheetal Nandi <shkamat@microsoft.com>

* Lint

Co-authored-by: Sheetal Nandi <shkamat@microsoft.com>
2020-07-22 13:53:30 -07:00

25 lines
644 B
TypeScript

/// <reference path="../fourslash.ts" />
// @Filename: /a/package.json
//// { "dependencies": { "b": "*" } }
// @Filename: /a/tsconfig.json
//// { "compilerOptions": { "module": "commonjs", "target": "esnext" }, "references": [{ "path": "../b" }] }
// @Filename: /a/index.ts
//// new Shape/**/
// @Filename: /b/package.json
//// { "types": "out/index.d.ts" }
// @Filename: /b/tsconfig.json
//// { "compilerOptions": { "outDir": "out", "composite": true } }
// @Filename: /b/index.ts
//// export class Shape {}
// @link: /b -> /a/node_modules/b
goTo.marker();
verify.importFixAtPosition([`import { Shape } from "b";\r\n\r\nnew Shape`]);