Merge pull request #21269 from Microsoft/fix-node_modules-deletion-in-external-compile-runner
Fix deletion of node_modules in DT test
This commit is contained in:
commit
ca65b6a789
1 changed files with 1 additions and 1 deletions
|
@ -61,7 +61,7 @@ abstract class ExternalCompileRunnerBase extends RunnerBase {
|
|||
fs.unlinkSync(path.join(cwd, "package-lock.json"));
|
||||
}
|
||||
if (fs.existsSync(path.join(cwd, "node_modules"))) {
|
||||
require("del").sync(path.join(cwd, "node_modules"));
|
||||
require("del").sync(path.join(cwd, "node_modules"), { force: true });
|
||||
}
|
||||
const install = cp.spawnSync(`npm`, ["i"], { cwd, timeout, shell: true, stdio });
|
||||
if (install.status !== 0) throw new Error(`NPM Install for ${directoryName} failed: ${install.stderr.toString()}`);
|
||||
|
|
Loading…
Reference in a new issue