test: break up node-http.test.ts (#23125)

This commit is contained in:
Meghan Denny
2025-09-30 16:25:17 -08:00
committed by GitHub
parent eac82e2184
commit f19a1cc3a5
74 changed files with 1847 additions and 1729 deletions

View File

@@ -579,8 +579,11 @@ async function runTests() {
const title = relative(cwd, absoluteTestPath).replaceAll(sep, "/");
if (isNodeTest(testPath)) {
const testContent = readFileSync(absoluteTestPath, "utf-8");
const runWithBunTest =
title.includes("needs-test") || testContent.includes("bun:test") || testContent.includes("node:test");
let runWithBunTest = title.includes("needs-test") || testContent.includes("node:test");
// don't wanna have a filter for includes("bun:test") but these need our mocks
runWithBunTest ||= title === "test/js/node/test/parallel/test-fs-append-file-flush.js";
runWithBunTest ||= title === "test/js/node/test/parallel/test-fs-write-file-flush.js";
runWithBunTest ||= title === "test/js/node/test/parallel/test-fs-write-stream-flush.js";
const subcommand = runWithBunTest ? "test" : "run";
const env = {
FORCE_COLOR: "0",