%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
// Flags: --allow_natives_syntax 'use strict'; const common = require('../common'); const assert = require('assert'); const http = require('http'); const server = http.createServer(onrequest).listen(0, common.localhostIPv4, () => next(0)); function onrequest(req, res) { res.end('ok'); onrequest.requests.push(req); onrequest.responses.push(res); } onrequest.requests = []; onrequest.responses = []; function next(n) { const { address: host, port } = server.address(); const req = http.get({ host, port }); req.once('response', (res) => onresponse(n, req, res)); } function onresponse(n, req, res) { res.resume(); if (n < 3) { res.once('end', () => next(n + 1)); } else { server.close(); } onresponse.requests.push(req); onresponse.responses.push(res); } onresponse.requests = []; onresponse.responses = []; function allSame(list) { assert(list.length >= 2); // eslint-disable-next-line no-unused-vars for (const elt of list) eval('%DebugPrint(elt)'); // eslint-disable-next-line no-unused-vars for (const elt of list) assert(eval('%HaveSameMap(list[0], elt)')); } process.on('exit', () => { eval('%CollectGarbage(0)'); // TODO(bnoordhuis) Investigate why the first IncomingMessage ends up // with a deprecated map. The map is stable after the first request. allSame(onrequest.requests.slice(1)); allSame(onrequest.responses); allSame(onresponse.requests); allSame(onresponse.responses); });