MCPcopy
hub / github.com/socketio/socket.io / testSourceMap

Function testSourceMap

packages/socket.io/test/server-attachment.ts:30–46  ·  view source on GitHub ↗
(filename)

Source from the content-addressed store, hash-verified

28 };
29
30 const testSourceMap = (filename) => (done) => {
31 const srv = createServer();
32 new Server(srv);
33 request(srv)
34 .get("/socket.io/" + filename)
35 .buffer(true)
36 .end((err, res) => {
37 if (err) return done(err);
38 expect(res.headers["content-type"]).to.be(
39 "application/json; charset=utf-8",
40 );
41 expect(res.headers.etag).to.be('"' + clientVersion + '"');
42 expect(res.text).to.match(/engine\.io/);
43 expect(res.status).to.be(200);
44 done();
45 });
46 };
47
48 it("should serve client", testSource("socket.io.js"));
49 it(

Callers 1

Calls 4

createServerFunction · 0.85
doneFunction · 0.85
matchMethod · 0.80
endMethod · 0.45

Tested by

no test coverage detected