Skip to content

Commit c9d51d3

Browse files
committed
fix(core): update cleanup mock to match async signature in package-json spec
1 parent 7c4f4af commit c9d51d3

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/nx/src/utils/package-json.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,9 @@ describe('installPackageToTmp', () => {
3838

3939
it('should always disable lifecycle scripts via environment variables', () => {
4040
const tempDir = mkdtempSync(join(tmpdir(), 'nx-install-test-'));
41-
const cleanup = jest.fn(() =>
42-
rmSync(tempDir, { recursive: true, force: true })
43-
);
41+
const cleanup = jest.fn(async () => {
42+
rmSync(tempDir, { recursive: true, force: true });
43+
});
4444
jest.spyOn(pacakgeManager, 'createTempNpmDirectory').mockReturnValue({
4545
dir: tempDir,
4646
cleanup,

0 commit comments

Comments
 (0)