Skip to content

Commit

Permalink
test/install: Use separate runDir for each test
Browse files Browse the repository at this point in the history
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
  • Loading branch information
vvoland committed Nov 8, 2024
1 parent 37b0f81 commit 4980de3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions __tests__/docker/install.test.itg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import {Install, InstallSourceArchive, InstallSourceImage} from '../../src/docke
import {Docker} from '../../src/docker/docker';
import {Exec} from '../../src/exec';

const tmpDir = fs.mkdtempSync(path.join(process.env.TEMP || os.tmpdir(), 'docker-install-itg-'));
const tmpDir = () => fs.mkdtempSync(path.join(process.env.TEMP || os.tmpdir(), 'docker-install-itg-'));

describe('install', () => {
const originalEnv = process.env;
Expand Down Expand Up @@ -51,7 +51,7 @@ aarch64:https://cloud.debian.org/images/cloud/bookworm/20231013-1532/debian-12-g
await ensureNoSystemContainerd();
const install = new Install({
source: source,
runDir: tmpDir,
runDir: tmpDir(),
contextName: 'foo',
daemonConfig: `{"debug":true,"features":{"containerd-snapshotter":true}}`
});
Expand All @@ -74,7 +74,7 @@ describe('rootless', () => {
await ensureNoSystemContainerd();
const install = new Install({
source: source,
runDir: tmpDir,
runDir: tmpDir(),
contextName: 'foo',
daemonConfig: `{"debug":true}`,
rootless: true
Expand Down

0 comments on commit 4980de3

Please sign in to comment.