Skip to content

Commit

Permalink
chore(tests): do not use outdated fs.rmdir API (#487)
Browse files Browse the repository at this point in the history
  • Loading branch information
aduh95 authored May 31, 2024
1 parent e1abb83 commit 7b8e33a
Show file tree
Hide file tree
Showing 2 changed files with 357 additions and 360 deletions.
4 changes: 2 additions & 2 deletions tests/main.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -835,7 +835,7 @@ it(`should be able to show the latest version`, async () => {
});

// Should keep working if the home folder is removed
await xfs.rmdirPromise(process.env.COREPACK_HOME as any, {recursive: true});
await xfs.rmPromise(process.env.COREPACK_HOME as any, {recursive: true});
await expect(runCli(cwd, [`yarn`, `--version`])).resolves.toMatchObject({
exitCode: 0,
stdout: /^1\.\d+\.\d+\r?\n$/,
Expand Down Expand Up @@ -972,7 +972,7 @@ describe(`handle integrity checks`, () => {
if (process.version.startsWith(`v18.`) && os.platform() === `win32`) return;

// Removing home directory to force the "re-download"
await xfs.rmdirPromise(process.env.COREPACK_HOME as any, {recursive: true});
await xfs.rmPromise(process.env.COREPACK_HOME as any, {recursive: true});

await Promise.all([
expect(runCli(cwd, [`use`, `pnpm`], true)).resolves.toMatchObject({
Expand Down
Loading

0 comments on commit 7b8e33a

Please sign in to comment.