Skip to content

Commit 6c31d71

Browse files
authored
test: hook timeout on Windows CI (#466)
1 parent 39a09cc commit 6c31d71

File tree

1 file changed

+19
-20
lines changed

1 file changed

+19
-20
lines changed

integration/theme-resolving/inline-content.test.ts

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,25 @@ const baseDir = path.resolve(__dirname, '../..');
99
const cli = path.join(baseDir, 'packages/cli/dist/index.js');
1010
const tmp = temporaryDirectory();
1111

12-
afterAll(async () => {
13-
await fs.rm(tmp, { force: true, recursive: true });
14-
});
15-
16-
test(
17-
'getInlineContentForPackage finds files from @tutorialkit/astro',
18-
{ timeout: process.env.CI ? 60_000 : 10_000 },
12+
afterAll(
1913
async () => {
20-
await execa(
21-
'node',
22-
[cli, 'create', 'theme-test', '--install', '--no-git', '--no-start', '--package-manager', 'pnpm', '--defaults'],
23-
{ cwd: tmp },
24-
);
25-
26-
const content = getInlineContentForPackage({
27-
name: '@tutorialkit/astro',
28-
pattern: '/dist/default/**/*.astro',
29-
root: `${tmp}/theme-test`,
30-
});
31-
32-
expect(content.length).toBeGreaterThan(0);
14+
await fs.rm(tmp, { force: true, recursive: true });
3315
},
16+
process.env.CI ? 60_000 : 10_000,
3417
);
18+
19+
test('getInlineContentForPackage finds files from @tutorialkit/astro', async () => {
20+
await execa(
21+
'node',
22+
[cli, 'create', 'theme-test', '--install', '--no-git', '--no-start', '--package-manager', 'pnpm', '--defaults'],
23+
{ cwd: tmp },
24+
);
25+
26+
const content = getInlineContentForPackage({
27+
name: '@tutorialkit/astro',
28+
pattern: '/dist/default/**/*.astro',
29+
root: `${tmp}/theme-test`,
30+
});
31+
32+
expect(content.length).toBeGreaterThan(0);
33+
});

0 commit comments

Comments
 (0)