fix: revert rm to rmdirSync so we don't remove config files before a test has been completed

This commit is contained in:
William Grant 2023-07-20 14:29:09 +10:00
parent 5d73e4e0f1
commit 69c8bd7553
1 changed files with 2 additions and 2 deletions

View File

@ -1,5 +1,5 @@
import { Page } from '@playwright/test';
import { readdirSync, rm } from 'fs-extra';
import { readdirSync, rmdirSync } from 'fs-extra';
import { join } from 'path';
import { homedir } from 'os';
import { isLinux, isMacOS } from '../../../OS';
@ -43,7 +43,7 @@ function cleanUpOtherTest() {
allAppDataPath.map(folder => {
const pathToRemove = join(parentFolderOfAllDataPath, folder);
rm(pathToRemove, { recursive: true }, () => pathToRemove);
rmdirSync(pathToRemove, { recursive: true });
});
console.info('...done');
}