ladjs / superagent

Ajax for Node.js and browsers (JS HTTP client). Maintained for @forwardemail, @ladjs, @spamscanner, @breejs, @cabinjs, and @lassjs.
https://ladjs.github.io/superagent/
MIT License
16.56k stars 1.33k forks source link

http2 test fix #1723

Closed yunnysunny closed 2 years ago

yunnysunny commented 2 years ago

Fix the test on http2.

  1. There is an issue in express-session https://github.com/expressjs/session/issues/888 , it call _implicitHeader on Http2ServerResponse, which is not exist. So I add a property named _implicitHeader on Http2ServerResponse in test file test/node/agency.js.
  2. The test/support/express/responseDecorator.js call the package statuses in wrong way. So I fixed it.
  3. All node version will try to test on http2 now.
  4. There an confused test case in test/node/http2.js , I have no idea what it wanna test. So I skp it.
codecov-commenter commented 2 years ago

Codecov Report

Merging #1723 (b8bf5e8) into master (34c9ff4) will increase coverage by 7.32%. The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1723      +/-   ##
==========================================
+ Coverage   86.76%   94.08%   +7.32%     
==========================================
  Files          14       14              
  Lines        1133     1133              
==========================================
+ Hits          983     1066      +83     
+ Misses        150       67      -83     
Impacted Files Coverage Δ
src/node/index.js 93.64% <0.00%> (+0.37%) :arrow_up:
src/node/http2wrapper.js 96.29% <0.00%> (+75.00%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 34c9ff4...b8bf5e8. Read the comment docs.