chore: refactor tests (#3243)

This commit is contained in:
Marvin Hagemeister
2025-08-22 12:14:19 +02:00
committed by GitHub
parent 873c54bd5f
commit 5c3fe27046
7 changed files with 252 additions and 459 deletions
+8 -6
View File
@@ -95,13 +95,15 @@ export async function withBrowser(fn: (page: Page) => void | Promise<void>) {
}
}
export interface TestChildServerOptions {
cwd: string;
args: string[];
bin?: string;
env?: Record<string, string>;
}
export async function withChildProcessServer(
options: {
cwd: string;
args: string[];
bin?: string;
env?: Record<string, string>;
},
options: TestChildServerOptions,
fn: (address: string) => void | Promise<void>,
) {
const aborter = new AbortController();