mirror of
https://github.com/microsoft/playwright.git
synced 2024-12-11 12:33:45 +03:00
test: remove itest folders using rimraf (#26646)
This should fix: Error: ENOTEMPTY: directory not empty, rmdir 'C:\Users\RUNNER~1\AppData\Local\Temp\pwt\workspaces\playwright-xyz-should-work-playwright-chromium-should-work-installation-tests\browsers\chromium-1076\chrome-win'
This commit is contained in:
parent
820611e3cc
commit
d08b38013d
@ -26,6 +26,7 @@ import { Registry } from './registry';
|
||||
import { spawnAsync } from './spawnAsync';
|
||||
import type { CommonFixtures, CommonWorkerFixtures } from '../config/commonFixtures';
|
||||
import { commonFixtures } from '../config/commonFixtures';
|
||||
import { removeFolders } from '../../packages/playwright-core/lib/utils/fileUtils';
|
||||
|
||||
|
||||
export const TMP_WORKSPACES = path.join(os.platform() === 'darwin' ? '/tmp' : os.tmpdir(), 'pwt', 'workspaces');
|
||||
@ -103,7 +104,7 @@ export const test = _test
|
||||
await use();
|
||||
if (test.info().status === test.info().expectedStatus) {
|
||||
// Browsers are large, we remove them after each test to save disk space.
|
||||
await fs.promises.rm(_browsersPath, { recursive: true, force: true });
|
||||
await removeFolders([_browsersPath]);
|
||||
}
|
||||
}, {
|
||||
auto: true,
|
||||
|
Loading…
Reference in New Issue
Block a user