Permalink
Browse files

test, feat: test for maxBodySize limit in the compressed body.

  • Loading branch information...
xicilion committed Jun 24, 2018
1 parent 3d8c5e9 commit 502b087306ef8f5963c41c74a4ee3fe022fd6a92
Showing with 12 additions and 0 deletions.
  1. +12 −0 test/http_test.js
View
@@ -1466,6 +1466,18 @@ describe("http", () => {
assert.equal(cookie, "root=value2");
http.get("http://127.0.0.1:" + (8882 + base_port) + "/gzip_test");
assert.equal(cookie, "root=value2; gzip_test=value");
var maxBodySize = http.maxBodySize;
http.maxBodySize = 130;
http.get("http://127.0.0.1:" + (8882 + base_port) + "/gzip_test");
http.maxBodySize = 129;
assert.throws(() => {
http.get("http://127.0.0.1:" + (8882 + base_port) + "/gzip_test");
});
http.maxBodySize = maxBodySize;
});
it("keep-alive", () => {

0 comments on commit 502b087

Please sign in to comment.