Skip to content

Commit adffc39

Browse files
committed
Increase timeout for Windows
1 parent 049e531 commit adffc39

File tree

1 file changed

+22
-12
lines changed

1 file changed

+22
-12
lines changed

packages/openapi-typescript/test/yaml.test.ts

+22-12
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,20 @@ import { execa } from "execa";
22
import os from "node:os";
33
import { fileURLToPath } from "node:url";
44

5+
const TIMEOUT = 15_000;
6+
57
const root = new URL("../", import.meta.url);
68
const cwd = os.platform() === "win32" ? fileURLToPath(root) : root; // execa bug: fileURLToPath required on Windows
79
const cmd = "./bin/cli.js";
810

911
describe("YAML features", () => {
10-
test("merge", async () => {
11-
const result = await execa(cmd, ["./test/fixtures/yaml-merge.yaml"], {
12-
cwd,
13-
});
14-
expect(result.stdout).toBe(`/**
12+
test(
13+
"merge",
14+
async () => {
15+
const result = await execa(cmd, ["./test/fixtures/yaml-merge.yaml"], {
16+
cwd,
17+
});
18+
expect(result.stdout).toBe(`/**
1519
* This file was auto-generated by openapi-typescript.
1620
* Do not make direct changes to the file.
1721
*/
@@ -84,13 +88,17 @@ export interface operations {
8488
};
8589
};
8690
}`);
87-
});
91+
},
92+
{ timeout: TIMEOUT },
93+
);
8894

89-
test("not ignore path item components in paths", async () => {
90-
const result = await execa(cmd, ["./test/fixtures/path-item-components.yaml"], {
91-
cwd,
92-
});
93-
expect(result.stdout).toBe(`/**
95+
test(
96+
"not ignore path item components in paths",
97+
async () => {
98+
const result = await execa(cmd, ["./test/fixtures/path-item-components.yaml"], {
99+
cwd,
100+
});
101+
expect(result.stdout).toBe(`/**
94102
* This file was auto-generated by openapi-typescript.
95103
* Do not make direct changes to the file.
96104
*/
@@ -165,5 +173,7 @@ export interface operations {
165173
};
166174
};
167175
}`);
168-
});
176+
},
177+
{ timeout: TIMEOUT },
178+
);
169179
});

0 commit comments

Comments
 (0)