diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 572c0b890..478c85918 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -12,7 +12,7 @@ jobs: strategy: matrix: os: [ubuntu-latest, macos-latest, windows-latest] - node: [12, 14] + node: [16, 18, 20] steps: - uses: actions/checkout@v2 - name: Setup node diff --git a/jest/helpers.js b/jest/helpers.js index 64bd2b6bd..c6b6e0e55 100644 --- a/jest/helpers.js +++ b/jest/helpers.js @@ -25,6 +25,6 @@ export const runPromptWithAnswers = (args, answers, testPath) => { // Cleanup export const rmTempDir = (tempDirPath) => { if (fs.existsSync(tempDirPath)) { - fs.rmdirSync(tempDirPath, { recursive: true }); + fs.rm(tempDirPath, { recursive: true }); } }; diff --git a/src/utils/__tests__/helpers.test.js b/src/utils/__tests__/helpers.test.js index 31bc14237..69c1cd860 100644 --- a/src/utils/__tests__/helpers.test.js +++ b/src/utils/__tests__/helpers.test.js @@ -23,11 +23,11 @@ beforeAll(() => { afterAll(() => { // copyDirSync() - fs.rmdirSync(srcPath, { recursive: true }); - fs.rmdirSync(destPath, { recursive: true }); + fs.rm(srcPath, { recursive: true }); + fs.rm(destPath, { recursive: true }); // fetchProjectConfig() - fs.rmdirSync(genPath, { recursive: true }); + fs.rm(genPath, { recursive: true }); }); test('copyDirSync()', () => {