Skip to content

Commit

Permalink
fix(node-http-handler): set maxSockets above 0 in test (#1660)
Browse files Browse the repository at this point in the history
  • Loading branch information
mhart authored Nov 5, 2020
1 parent eb50962 commit 706768d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/node-http-handler/src/node-http-handler.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ import {
describe("NodeHttpHandler", () => {
describe("constructor", () => {
it("can set httpAgent and httpsAgent", () => {
let maxSockets = Math.round(Math.random() * 50);
let maxSockets = Math.round(Math.random() * 50) + 1;
let nodeHttpHandler = new NodeHttpHandler({
httpAgent: new http.Agent({ maxSockets }),
});
expect((nodeHttpHandler as any).httpAgent.maxSockets).toEqual(maxSockets);
maxSockets = Math.round(Math.random() * 50);
maxSockets = Math.round(Math.random() * 50) + 1;
nodeHttpHandler = new NodeHttpHandler({
httpsAgent: new https.Agent({ maxSockets }),
});
Expand Down

0 comments on commit 706768d

Please sign in to comment.