From d6c08bbc580b20dc5abe8c7cc81d3d6791495b61 Mon Sep 17 00:00:00 2001 From: robobun <117481402+robobun@users.noreply.github.com> Date: Sat, 15 Aug 2026 12:57:17 +0000 Subject: [PATCH] test: enable stale todo tests that now pass 58 tests in 27 files were marked todo but pass at HEAD (bun test --todo flags them). Remove the markers, and fix the bodies that were the actual problem: the Readable _events test asserted Writable's keys, the express name.txt fixture had a trailing newline that upstream's does not, the bunfig plugin preload fixture no longer proved the preload ran once .yaml imports became native, the serve Range tests accepted both outcomes, the spawn cancel test relied on sleeps, and the CONNECT socket timeout test wrote after end() when the idle timer re-fired during a slow close. --- test/bundler/esbuild/dce.test.ts | 1 - test/bundler/esbuild/default.test.ts | 2 - test/bundler/esbuild/packagejson.test.ts | 1 - test/bundler/esbuild/splitting.test.ts | 1 - test/bundler/esbuild/ts.test.ts | 3 -- test/bundler/transpiler/transpiler.test.js | 2 +- test/cli/run/preload-test.test.js | 2 +- test/cli/test/bun-test.test.ts | 5 +- .../bunfig/fixtures/preload/plugin/index.ts | 4 ++ test/config/bunfig/preload.test.ts | 2 +- test/js/bun/http/bun-serve-file.test.ts | 20 +++---- ...n-stdin-readable-stream-edge-cases.test.ts | 52 ++++++------------- test/js/bun/yaml/yaml.test.ts | 2 +- .../child_process/child_process-node.test.js | 3 +- test/js/node/http/node-http-connect.test.ts | 7 +-- test/js/node/stream/node-stream.test.js | 16 +++--- test/js/node/url/url-pathtofileurl.test.js | 6 +-- test/js/node/url/url-revokeobjecturl.test.js | 3 +- .../third_party/express/express.json.test.ts | 8 +-- .../third_party/express/express.text.test.ts | 12 ++--- test/js/third_party/express/fixtures/name.txt | 2 +- .../third_party/express/res.location.test.ts | 4 +- test/js/third_party/express/res.send.test.ts | 4 +- .../third_party/express/res.sendFile.test.ts | 24 ++++----- .../grpc-js/test-channel-credentials.test.ts | 2 +- .../third_party/grpc-js/test-server.test.ts | 5 +- .../jwt.asymmetric_signing.test.js | 2 +- .../validateAsymmetricKey.test.js | 4 +- .../third_party/jsonwebtoken/verify.test.js | 2 +- 29 files changed, 84 insertions(+), 117 deletions(-) diff --git a/test/bundler/esbuild/dce.test.ts b/test/bundler/esbuild/dce.test.ts index 59a64b1c0e3e..a5ab8a890adc 100644 --- a/test/bundler/esbuild/dce.test.ts +++ b/test/bundler/esbuild/dce.test.ts @@ -562,7 +562,6 @@ describe("bundler", () => { }, }); itBundled("dce/PackageJsonSideEffectsArrayKeepModuleImplicitMain", { - todo: true, files: { "/Users/user/project/src/entry.js": /* js */ ` import {foo} from "demo-pkg" diff --git a/test/bundler/esbuild/default.test.ts b/test/bundler/esbuild/default.test.ts index 950319df7bab..c295cbe9ef15 100644 --- a/test/bundler/esbuild/default.test.ts +++ b/test/bundler/esbuild/default.test.ts @@ -4752,7 +4752,6 @@ describe.concurrent("bundler", () => { }, }); itBundled("default/CharFreqIgnoreComments", { - todo: true, files: { "/a.js": /* js */ ` export default function(one, two, three, four) { @@ -5477,7 +5476,6 @@ describe.concurrent("bundler", () => { minifySyntax: true, }); itBundled("default/BuiltInNodeModulePrecedence", { - todo: true, files: { "/entry.js": /* js */ ` console.log([ diff --git a/test/bundler/esbuild/packagejson.test.ts b/test/bundler/esbuild/packagejson.test.ts index 4f17d2d55b84..c1b1c1dfba3e 100644 --- a/test/bundler/esbuild/packagejson.test.ts +++ b/test/bundler/esbuild/packagejson.test.ts @@ -909,7 +909,6 @@ describe("bundler", () => { }, }); itBundled("packagejson/DualPackageHazardImportAndRequireBrowser", { - todo: true, files: { "/Users/user/project/src/entry.js": /* js */ ` import './test-main' diff --git a/test/bundler/esbuild/splitting.test.ts b/test/bundler/esbuild/splitting.test.ts index 303127f136ba..44fc6b88515e 100644 --- a/test/bundler/esbuild/splitting.test.ts +++ b/test/bundler/esbuild/splitting.test.ts @@ -217,7 +217,6 @@ describe("bundler", () => { ], }); itBundled("splitting/CircularReferenceESBuildIssue251", { - todo: true, files: { "/a.js": /* js */ ` export * from './b.js'; diff --git a/test/bundler/esbuild/ts.test.ts b/test/bundler/esbuild/ts.test.ts index d026d000f1dc..f99ecd43e301 100644 --- a/test/bundler/esbuild/ts.test.ts +++ b/test/bundler/esbuild/ts.test.ts @@ -2025,9 +2025,6 @@ describe("bundler", () => { minifySyntax: false, // intentionally disabled. enum inlining always happens }); itBundled("ts/EnumJSX", { - // Blocking: - // - jsx bugs (configuration does not seem to be respected) - todo: true, files: { "/element.tsx": /* tsx */ ` import { create } from 'not-react' diff --git a/test/bundler/transpiler/transpiler.test.js b/test/bundler/transpiler/transpiler.test.js index a9a0d382aaed..867ca733a0a6 100644 --- a/test/bundler/transpiler/transpiler.test.js +++ b/test/bundler/transpiler/transpiler.test.js @@ -2898,7 +2898,7 @@ console.log(a) `); }); - it.todo("macros can return a promise", () => { + it("macros can return a promise", () => { var object = { helloooooooo: { message: [12345], diff --git a/test/cli/run/preload-test.test.js b/test/cli/run/preload-test.test.js index 72f9ddd9538a..bc449431b94d 100644 --- a/test/cli/run/preload-test.test.js +++ b/test/cli/run/preload-test.test.js @@ -118,7 +118,7 @@ plugin({ }); `; - test.todo("works from CLI", async () => { + test("works from CLI", async () => { const preloadDir = join(realpathSync(tmpdir()), "bun-preload-test6"); mkdirSync(preloadDir, { recursive: true }); const preloadPath = join(preloadDir, "preload.js"); diff --git a/test/cli/test/bun-test.test.ts b/test/cli/test/bun-test.test.ts index f582b871d8f5..7c006b86cf21 100644 --- a/test/cli/test/bun-test.test.ts +++ b/test/cli/test/bun-test.test.ts @@ -58,8 +58,7 @@ describe("bun test", () => { }); expect(stderr).toContain(path); }); - // This fails on macOS because /private/var symlinks to /var - test.todo("can provide an absolute file", () => { + test("can provide an absolute file", () => { const path = join("path", "to", "absolute.test.ts"); const cwd = createTest( ` @@ -95,7 +94,7 @@ describe("bun test", () => { }); expect(stderr).toContain(dir); }); - test.todo("can provide an absolute directory", () => { + test("can provide an absolute directory", () => { const path = join("path", "to", "absolute.test.ts"); const cwd = createTest( ` diff --git a/test/config/bunfig/fixtures/preload/plugin/index.ts b/test/config/bunfig/fixtures/preload/plugin/index.ts index e7e016029c74..99c92df4e660 100644 --- a/test/config/bunfig/fixtures/preload/plugin/index.ts +++ b/test/config/bunfig/fixtures/preload/plugin/index.ts @@ -2,3 +2,7 @@ import assert from "node:assert"; import foo from "./foo.yaml"; assert(foo); assert.equal(typeof foo, "object"); +// bun-plugin-yaml only exports a plugin factory (it registers nothing), and +// .yaml imports work natively, so the import above does not prove the preload +// ran. Its presence in the module cache does. +assert(require.resolve("bun-plugin-yaml") in require.cache, "bunfig preload was not loaded"); diff --git a/test/config/bunfig/preload.test.ts b/test/config/bunfig/preload.test.ts index 44daf6c91deb..3047982f7c80 100644 --- a/test/config/bunfig/preload.test.ts +++ b/test/config/bunfig/preload.test.ts @@ -107,7 +107,7 @@ describe("Given a `bunfig.toml` with a list of preloads", () => { describe("Given a `bunfig.toml` with a plugin preload", () => { const dir = fixturePath("plugin"); - it.todo("When `bun run` is run, preloads are run", async () => { + it("When `bun run` is run, preloads are run", async () => { const [out, err, code] = await run("index.ts", { cwd: dir }); expect(err).toBeEmpty(); expect(out).toBeEmpty(); diff --git a/test/js/bun/http/bun-serve-file.test.ts b/test/js/bun/http/bun-serve-file.test.ts index dada59606156..a292206b2c28 100644 --- a/test/js/bun/http/bun-serve-file.test.ts +++ b/test/js/bun/http/bun-serve-file.test.ts @@ -298,7 +298,7 @@ describe("Bun.file in serve routes", () => { }); }); - describe.todo("Range requests", () => { + describe.concurrent("Range requests", () => { it("supports partial content requests", async () => { const res = await fetch(new URL(`/hello.txt`, server.url), { headers: { @@ -306,15 +306,10 @@ describe("Bun.file in serve routes", () => { }, }); - if (res.status === 206) { - expect(await res.text()).toBe("Hello"); - expect(res.headers.get("Content-Range")).toMatch(/bytes 0-4\/13/); - expect(res.headers.get("Accept-Ranges")).toBe("bytes"); - } else { - // If range requests aren't supported, should return full content - expect(res.status).toBe(200); - expect(await res.text()).toBe("Hello, World!"); - } + expect(res.status).toBe(206); + expect(res.headers.get("Content-Range")).toBe("bytes 0-4/13"); + expect(res.headers.get("Accept-Ranges")).toBe("bytes"); + expect(await res.text()).toBe("Hello"); }); it("handles invalid range requests", async () => { @@ -324,8 +319,9 @@ describe("Bun.file in serve routes", () => { }, }); - // Should either return 416 Range Not Satisfiable or 200 with full content - expect([200, 416]).toContain(res.status); + expect(res.status).toBe(416); + expect(res.headers.get("Content-Range")).toBe("bytes */13"); + expect(await res.text()).toBe(""); }); }); diff --git a/test/js/bun/spawn/spawn-stdin-readable-stream-edge-cases.test.ts b/test/js/bun/spawn/spawn-stdin-readable-stream-edge-cases.test.ts index ff4a3e986720..20ab4aa6f672 100644 --- a/test/js/bun/spawn/spawn-stdin-readable-stream-edge-cases.test.ts +++ b/test/js/bun/spawn/spawn-stdin-readable-stream-edge-cases.test.ts @@ -175,37 +175,20 @@ describe("spawn stdin ReadableStream edge cases", () => { expect(await proc.exited).toBe(0); }); - test.todo("ReadableStream with cancel callback verification", async () => { - let cancelReason: any = null; - let cancelCalled = false; + test("ReadableStream with cancel callback verification", async () => { + const cancelled = Promise.withResolvers(); + // Never closes: the only way this stream ends is spawn cancelling it. const stream = new ReadableStream({ start(controller) { - // Start sending data - let count = 0; - const interval = setInterval(() => { - count++; - try { - controller.enqueue(`data ${count}\n`); - } catch (e) { - clearInterval(interval); - } - }, 50); - - // Store interval for cleanup - (controller as any).interval = interval; + controller.enqueue("data\n"); }, - cancel(reason) { - cancelCalled = true; - cancelReason = reason; - // Clean up interval if exists - if ((this as any).interval) { - clearInterval((this as any).interval); - } + pull() {}, + cancel() { + cancelled.resolve(); }, }); - // Kill the process after some data const proc = spawn({ cmd: [bunExe(), "-e", "process.stdin.pipe(process.stdout)"], stdin: stream, @@ -213,20 +196,17 @@ describe("spawn stdin ReadableStream edge cases", () => { env: bunEnv, }); - // Wait a bit then kill - await Bun.sleep(150); - proc.kill(); - - try { - await proc.exited; - } catch (e) { - // Expected - process was killed - } + // Kill only once the chunk has made the round trip, so the stream is + // attached to stdin and waiting for more data at that point. + const reader = proc.stdout.getReader(); + const { value } = await reader.read(); + expect(new TextDecoder().decode(value)).toBe("data\n"); + reader.releaseLock(); - // Give time for cancel to be called - await Bun.sleep(50); + proc.kill(); + await proc.exited; - expect(cancelCalled).toBe(true); + await cancelled.promise; }); test("ReadableStream with high frequency small chunks", async () => { diff --git a/test/js/bun/yaml/yaml.test.ts b/test/js/bun/yaml/yaml.test.ts index db877dbca7df..99900240eed5 100644 --- a/test/js/bun/yaml/yaml.test.ts +++ b/test/js/bun/yaml/yaml.test.ts @@ -4323,7 +4323,7 @@ refs: expect(yaml2).toBe("counter: 4"); }); - test.todo("handles circular getters", () => { + test("handles circular getters", () => { const obj = { get self() { return obj; diff --git a/test/js/node/child_process/child_process-node.test.js b/test/js/node/child_process/child_process-node.test.js index 4a5b29897903..42b7d9417743 100644 --- a/test/js/node/child_process/child_process-node.test.js +++ b/test/js/node/child_process/child_process-node.test.js @@ -750,8 +750,7 @@ describe("fork", () => { // https://github.com/nodejs/node/blob/v20.5.0/test/parallel/test-child-process-fork-stdio.js }); describe("fork", () => { - it.todo("message", done => { - // TODO - bun has no `send` method in the process + it("message", done => { const { mustCall } = createCallCheckCtx(done); const args = ["foo", "bar"]; const n = fork(fixtures.path("child-process-spawn-node.js"), args); diff --git a/test/js/node/http/node-http-connect.test.ts b/test/js/node/http/node-http-connect.test.ts index 5560da659b0c..fa5db8a8f536 100644 --- a/test/js/node/http/node-http-connect.test.ts +++ b/test/js/node/http/node-http-connect.test.ts @@ -185,14 +185,15 @@ describe("HTTP server CONNECT", () => { expect(response).toContain("502 Bad Gateway"); }); - // TODO: timeout is not supported in bun socket yet - test.todo("should handle socket timeout", async () => { + test("should handle socket timeout", async () => { await using proxyServer = http.createServer(); let timeoutFired = false; proxyServer.on("connect", (req, socket, head) => { socket.setTimeout(100); - socket.on("timeout", () => { + // The idle timer re-arms after the write below, so a slow close fires + // 'timeout' again; a second handler run would write after end(). + socket.once("timeout", () => { timeoutFired = true; socket.write("HTTP/1.1 408 Request Timeout\r\n\r\n"); socket.end(); diff --git a/test/js/node/stream/node-stream.test.js b/test/js/node/stream/node-stream.test.js index 7bdac29ba752..0150eb9cc418 100644 --- a/test/js/node/stream/node-stream.test.js +++ b/test/js/node/stream/node-stream.test.js @@ -156,13 +156,13 @@ describe("Readable", () => { stream.pipe(writable); }); - it.todo("should have the correct fields in _events", () => { + it("should have the correct fields in _events", () => { const s = Readable({}); expect(s._events).toHaveProperty("close"); expect(s._events).toHaveProperty("error"); - expect(s._events).toHaveProperty("prefinish"); - expect(s._events).toHaveProperty("finish"); - expect(s._events).toHaveProperty("drain"); + expect(s._events).toHaveProperty("data"); + expect(s._events).toHaveProperty("end"); + expect(s._events).toHaveProperty("readable"); }); }); @@ -205,7 +205,7 @@ describe("createReadStream", () => { }); describe("Writable", () => { - it.todo("should have the correct fields in _events", () => { + it("should have the correct fields in _events", () => { const s = Writable({}); expect(s._events).toHaveProperty("close"); expect(s._events).toHaveProperty("error"); @@ -229,7 +229,7 @@ describe("Duplex", () => { expect(subclass instanceof Duplex).toBe(true); }); - it.todo("should have the correct fields in _events", () => { + it("should have the correct fields in _events", () => { const s = Duplex({}); expect(s._events).toHaveProperty("close"); expect(s._events).toHaveProperty("error"); @@ -256,7 +256,7 @@ describe("Transform", () => { expect(subclass instanceof Transform).toBe(true); }); - it.todo("should have the correct fields in _events", () => { + it("should have the correct fields in _events", () => { const s = Transform({}); expect(s._events).toHaveProperty("close"); expect(s._events).toHaveProperty("error"); @@ -283,7 +283,7 @@ describe("PassThrough", () => { expect(subclass instanceof PassThrough).toBe(true); }); - it.todo("should have the correct fields in _events", () => { + it("should have the correct fields in _events", () => { const s = PassThrough({}); expect(s._events).toHaveProperty("close"); expect(s._events).toHaveProperty("error"); diff --git a/test/js/node/url/url-pathtofileurl.test.js b/test/js/node/url/url-pathtofileurl.test.js index 561cb3e3b8b9..c8f85f6eef28 100644 --- a/test/js/node/url/url-pathtofileurl.test.js +++ b/test/js/node/url/url-pathtofileurl.test.js @@ -27,8 +27,7 @@ describe("url.pathToFileURL", () => { // } }); - // TODO: Support UNC paths across platforms. - test.todo("UNC paths", () => { + test("UNC paths", () => { if (isWindows) { // UNC path: \\server\share\resource @@ -171,8 +170,7 @@ describe("url.pathToFileURL", () => { } }); - // TODO: Support throwing correct exception for non-string params. - test.todo("non-string parameter", () => { + test("non-string parameter", () => { for (const badPath of [ undefined, null, diff --git a/test/js/node/url/url-revokeobjecturl.test.js b/test/js/node/url/url-revokeobjecturl.test.js index 1c09aa71a1f4..ef236673796a 100644 --- a/test/js/node/url/url-revokeobjecturl.test.js +++ b/test/js/node/url/url-revokeobjecturl.test.js @@ -2,8 +2,7 @@ import { describe, test } from "bun:test"; import assert from "node:assert"; import { URL } from "node:url"; -// TODO: Support throwing appropriate error. -describe.todo("URL.revokeObjectURL", () => { +describe("URL.revokeObjectURL", () => { test("invalid input", () => { // Test ensures that the function receives the url argument. assert.throws( diff --git a/test/js/third_party/express/express.json.test.ts b/test/js/third_party/express/express.json.test.ts index 1cc87cf89bb5..e46bdfdc9d6c 100644 --- a/test/js/third_party/express/express.json.test.ts +++ b/test/js/third_party/express/express.json.test.ts @@ -25,7 +25,7 @@ describe("express.json()", function () { .expect(200, "{}", done); }); - it.todo("should handle empty message-body", function (done) { + it("should handle empty message-body", function (done) { request(createApp()) .post("/") .set("Content-Type", "application/json") @@ -201,7 +201,7 @@ describe("express.json()", function () { app = createApp({ inflate: false }); }); - it.todo("should not accept content-encoding", function (done) { + it("should not accept content-encoding", function (done) { var test = request(app).post("/"); test.set("Content-Encoding", "gzip"); test.set("Content-Type", "application/json"); @@ -245,7 +245,7 @@ describe("express.json()", function () { app = createApp({ strict: false }); }); - it.todo("should parse primitives", function (done) { + it("should parse primitives", function (done) { request(app).post("/").set("Content-Type", "application/json").send("true").expect(200, "true", done); }); }); @@ -326,7 +326,7 @@ describe("express.json()", function () { .expect(200, '{"user":"tobi"}', done); }); - it.todo('should parse JSON for "application/vnd.api+json"', function (done) { + it('should parse JSON for "application/vnd.api+json"', function (done) { request(app) .post("/") .set("Content-Type", "application/vnd.api+json") diff --git a/test/js/third_party/express/express.text.test.ts b/test/js/third_party/express/express.text.test.ts index 096ed48f21aa..d20e37c8e038 100644 --- a/test/js/third_party/express/express.text.test.ts +++ b/test/js/third_party/express/express.text.test.ts @@ -46,7 +46,7 @@ describe("express.text()", function () { .expect(200, '""', done); }); - it.todo("should handle empty message-body", function (done) { + it("should handle empty message-body", function (done) { request(createApp({ limit: "1kb" })) .post("/") .set("Content-Type", "text/plain") @@ -97,7 +97,7 @@ describe("express.text()", function () { .expect(413, done); }); - it.todo("should 413 when over limit with chunked encoding", function (done) { + it("should 413 when over limit with chunked encoding", function (done) { var app = createApp({ limit: "1kb" }); var buf = Buffer.alloc(1028, "."); var test = request(app).post("/"); @@ -159,7 +159,7 @@ describe("express.text()", function () { }); describe("with inflate option", function () { - describe.todo("when false", function () { + describe("when false", function () { beforeAll(function () { app = createApp({ inflate: false }); }); @@ -189,7 +189,7 @@ describe("express.text()", function () { }); describe("with type option", function () { - describe.todo('when "text/html"', function () { + describe('when "text/html"', function () { beforeAll(function () { app = createApp({ type: "text/html" }); }); @@ -198,7 +198,7 @@ describe("express.text()", function () { request(app).post("/").set("Content-Type", "text/html").send("tobi").expect(200, '"tobi"', done); }); - it("should ignore standard type", function (done) { + it.todo("should ignore standard type", function (done) { request(app).post("/").set("Content-Type", "text/plain").send("user is tobi").expect(200, "", done); }); }); @@ -208,7 +208,7 @@ describe("express.text()", function () { app = createApp({ type: ["text/html", "text/plain"] }); }); - it.todo('should parse "text/html"', function (done) { + it('should parse "text/html"', function (done) { request(app).post("/").set("Content-Type", "text/html").send("tobi").expect(200, '"tobi"', done); }); diff --git a/test/js/third_party/express/fixtures/name.txt b/test/js/third_party/express/fixtures/name.txt index 4599db462a5a..fa66f37ff217 100644 --- a/test/js/third_party/express/fixtures/name.txt +++ b/test/js/third_party/express/fixtures/name.txt @@ -1 +1 @@ -tobi +tobi \ No newline at end of file diff --git a/test/js/third_party/express/res.location.test.ts b/test/js/third_party/express/res.location.test.ts index 91df35f5e38e..188ed63b2566 100644 --- a/test/js/third_party/express/res.location.test.ts +++ b/test/js/third_party/express/res.location.test.ts @@ -79,7 +79,7 @@ describe("res", function () { request(app).get("/").expect("Location", "[object%20Object]").expect(200, done); }); - it.todo("should consistently handle non-string inputs: array", function (done) { + it("should consistently handle non-string inputs: array", function (done) { var app = express(); app.use(function (req, res) { res.location([]).end(); @@ -88,7 +88,7 @@ describe("res", function () { request(app).get("/").expect("Location", "").expect(200, done); }); - it.todo("should consistently handle empty string input", function (done) { + it("should consistently handle empty string input", function (done) { var app = express(); app.use(function (req, res) { res.location("").end(); diff --git a/test/js/third_party/express/res.send.test.ts b/test/js/third_party/express/res.send.test.ts index 72f2f09d441b..18fca2ad8e40 100644 --- a/test/js/third_party/express/res.send.test.ts +++ b/test/js/third_party/express/res.send.test.ts @@ -195,7 +195,7 @@ describe("res", function () { }); describe("when .statusCode is 204", function () { - it.todo("should strip Content-* fields, Transfer-Encoding field, and body", function (done) { + it("should strip Content-* fields, Transfer-Encoding field, and body", function (done) { var app = express(); app.use(function (req, res) { @@ -228,7 +228,7 @@ describe("res", function () { }); describe("when .statusCode is 304", function () { - it.todo("should strip Content-* fields, Transfer-Encoding field, and body", function (done) { + it("should strip Content-* fields, Transfer-Encoding field, and body", function (done) { var app = express(); app.use(function (req, res) { diff --git a/test/js/third_party/express/res.sendFile.test.ts b/test/js/third_party/express/res.sendFile.test.ts index 70091179afad..787fa751c292 100644 --- a/test/js/third_party/express/res.sendFile.test.ts +++ b/test/js/third_party/express/res.sendFile.test.ts @@ -37,7 +37,7 @@ describe("res", function () { .expect(500, /TypeError: path must be absolute/, done); }); - it.todo("should transfer a file", function (done) { + it("should transfer a file", function (done) { var app = createApp(path.resolve(fixtures, "name.txt")); request(app).get("/").expect(200, "tobi", done); @@ -49,7 +49,7 @@ describe("res", function () { request(app).get("/").expect(200, "20%", done); }); - it.todo("should include ETag", function (done) { + it("should include ETag", function (done) { var app = createApp(path.resolve(fixtures, "name.txt")); request(app) @@ -58,7 +58,7 @@ describe("res", function () { .expect(200, "tobi", done); }); - it.todo("should 304 when ETag matches", function (done) { + it("should 304 when ETag matches", function (done) { var app = createApp(path.resolve(fixtures, "name.txt")); request(app) @@ -121,7 +121,7 @@ describe("res", function () { request(app).get("/").expect("Content-Type", "application/x-bogus").end(done); }); - it.todo("should not error if the client aborts", function (done) { + it("should not error if the client aborts", function (done) { var app = express(); var cb = after(2, done); var error = null; @@ -158,7 +158,7 @@ describe("res", function () { request(app).get("/").expect(200, cb); }); - it.todo("should invoke the callback when client aborts", function (done) { + it("should invoke the callback when client aborts", function (done) { var cb = after(2, done); var app = express(); @@ -216,7 +216,7 @@ describe("res", function () { request(app).head("/").expect(200, cb); }); - it.todo("should invoke the callback without error when 304", function (done) { + it("should invoke the callback without error when 304", function (done) { var app = express(); var cb = after(3, done); @@ -246,8 +246,8 @@ describe("res", function () { request(app).get("/").expect(200, "got 404 error", done); }); - describe.todo("async local storage", function () { - it("should presist store", function (done) { + describe("async local storage", function () { + it.todo("should presist store", function (done) { var app = express(); var cb = after(2, done); var store = { foo: "bar" }; @@ -621,7 +621,7 @@ describe("res", function () { request(app).get("/").expect(200).expect("Cache-Control", "public, max-age=31536000").end(done); }); - it.todo("should min cache-control max-age to 0", function (done) { + it("should min cache-control max-age to 0", function (done) { var app = express(); app.use(function (req, res) { @@ -633,7 +633,7 @@ describe("res", function () { request(app).get("/").expect(200).expect("Cache-Control", "public, max-age=0").end(done); }); - it.todo("should floor cache-control max-age", function (done) { + it("should floor cache-control max-age", function (done) { var app = express(); app.use(function (req, res) { @@ -711,7 +711,7 @@ describe("res", function () { }); }); - describe.todo('with "root" option', function () { + describe('with "root" option', function () { it("should allow relative path", function (done) { var app = express(); @@ -736,7 +736,7 @@ describe("res", function () { request(app).get("/").expect(200, "tobi", done); }); - it.todo("should reject up outside root", function (done) { + it("should reject up outside root", function (done) { var app = express(); app.use(function (req, res) { diff --git a/test/js/third_party/grpc-js/test-channel-credentials.test.ts b/test/js/third_party/grpc-js/test-channel-credentials.test.ts index 2c9c64bb046c..6c8ddb3ef088 100644 --- a/test/js/third_party/grpc-js/test-channel-credentials.test.ts +++ b/test/js/third_party/grpc-js/test-channel-credentials.test.ts @@ -192,7 +192,7 @@ describe("ChannelCredentials usage", () => { assert2.afterMustCallsSatisfied(done); }); - it.todo("Should call the checkServerIdentity callback", done => { + it("Should call the checkServerIdentity callback", done => { const channelCreds = ChannelCredentials.createSsl(caCert, null, null, { checkServerIdentity: assert2.mustCall((hostname, cert) => { assert.strictEqual(hostname, hostnameOverride); diff --git a/test/js/third_party/grpc-js/test-server.test.ts b/test/js/third_party/grpc-js/test-server.test.ts index 607afbda7636..a3cf7325b41f 100644 --- a/test/js/third_party/grpc-js/test-server.test.ts +++ b/test/js/third_party/grpc-js/test-server.test.ts @@ -260,7 +260,7 @@ describe("Server", () => { server.forceShutdown(); }); - it.todo("Should cancel open calls after the grace period ends", done => { + it("Should cancel open calls after the grace period ends", done => { const call = client.echoBidiStream(); call.on("error", (error: ServiceError) => { assert.strictEqual(error.code, grpc.status.CANCELLED); @@ -808,8 +808,7 @@ describe("Echo service", () => { }); }); -// We dont allow connection injections yet on node:http nor node:http2 -describe.todo("Connection injector", () => { +describe("Connection injector", () => { let tcpServer: net.Server; let server: Server; let client: ServiceClient; diff --git a/test/js/third_party/jsonwebtoken/jwt.asymmetric_signing.test.js b/test/js/third_party/jsonwebtoken/jwt.asymmetric_signing.test.js index 347baa2891aa..a54b7c90d515 100644 --- a/test/js/third_party/jsonwebtoken/jwt.asymmetric_signing.test.js +++ b/test/js/third_party/jsonwebtoken/jwt.asymmetric_signing.test.js @@ -173,7 +173,7 @@ describe("Asymmetric Algorithms", function () { }); describe("when signing a token with an unsupported private key type", function () { - it.todo("should throw an error", function () { + it("should throw an error", function () { const obj = { foo: "bar" }; const key = loadKey("dsa-private.pem"); const algorithm = "RS256"; diff --git a/test/js/third_party/jsonwebtoken/validateAsymmetricKey.test.js b/test/js/third_party/jsonwebtoken/validateAsymmetricKey.test.js index 5ec597180331..0ee0aac496fd 100644 --- a/test/js/third_party/jsonwebtoken/validateAsymmetricKey.test.js +++ b/test/js/third_party/jsonwebtoken/validateAsymmetricKey.test.js @@ -115,14 +115,14 @@ describe("Asymmetric key validation", function () { validateAsymmetricKey(algorithm); }); - it.todo("should pass the validation if no algorithm has been provided", function () { + it("should pass the validation if no algorithm has been provided", function () { const key = loadKey("dsa-private.pem"); validateAsymmetricKey(null, key); }); }); describe("when validating a key with an unsupported type", function () { - it.todo("should throw an error", function () { + it("should throw an error", function () { const algorithm = "RS256"; const key = loadKey("dsa-private.pem"); const expectedErrorMessage = 'Unknown key type "dsa".'; diff --git a/test/js/third_party/jsonwebtoken/verify.test.js b/test/js/third_party/jsonwebtoken/verify.test.js index 55034e5878f2..d701d55df9e8 100644 --- a/test/js/third_party/jsonwebtoken/verify.test.js +++ b/test/js/third_party/jsonwebtoken/verify.test.js @@ -282,7 +282,7 @@ describe("verify", function () { }); }); - describe.todo("when verifying a token with an unsupported public key type", function () { + describe("when verifying a token with an unsupported public key type", function () { it("should throw an error", function () { const token = "eyJhbGciOiJSUzI1NiJ9.eyJpYXQiOjE2Njk5OTAwMDN9.YdjFWJtPg_9nccMnTfQyesWQ0UX-GsWrfCGit_HqjeIkNjoV6dkAJ8AtbnVEhA4oxwqSXx6ilMOfHEjmMlPtyyyVKkWKQHcIWYnqPbNSEv8a7Men8KhJTIWb4sf5YbhgSCpNvU_VIZjLO1Z0PzzgmEikp0vYbxZFAbCAlZCvUlcIc-kdjIRCnDJe0BBrYRxNLEJtYsf7D1yFIFIqw8-VP87yZdExA4eHsTaE84SgnL24ZK5h5UooDx-IRNd_rrMyio8kNy63grVxCWOtkXZ26iZk6v-HMsnBqxvUwR6-8wfaWrcpADkyUO1q3SNsoTdwtflbvfwgjo3uve0IvIzHMw";