MCPcopy Create free account
hub / github.com/ChromeDevTools/chrome-devtools-mcp / runTests

Function runTests

scripts/test.js:116–140  ·  view source on GitHub ↗
(attempt)

Source from the content-addressed store, hash-verified

114];
115
116async function runTests(attempt) {
117 if (attempt > 1) {
118 console.log(`\nRun attempt ${attempt}...\n`);
119 }
120 return await new Promise(resolve => {
121 const child = spawn(process.execPath, nodeArgs, {
122 cwd: projectRoot,
123 stdio: 'inherit',
124 env: {
125 ...process.env,
126 CHROME_DEVTOOLS_MCP_NO_USAGE_STATISTICS: true,
127 CHROME_DEVTOOLS_MCP_CRASH_ON_UNCAUGHT: true,
128 CHROME_DEVTOOLS_MCP_NO_UPDATE_CHECKS: true,
129 CHROME_DEVTOOLS_MCP_NO_CONFIG_DISCOVERY: true,
130 ...(process.env['RUNNER_DEBUG'] === '1'
131 ? {NODE_DEBUG: 'puppeteer:*'}
132 : {}),
133 },
134 });
135
136 child.on('close', code => {
137 resolve(code);
138 });
139 });
140}
141
142const maxAttempts = shouldRetry ? 3 : 1;
143let exitCode = 1;

Callers 1

test.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected