* Add failing tests for http2
* Add support for http2
The change just removes the usage of undocumented http API and instead uses the proper writeHead method
* Remove arrow function in tests
* Conditionally run http2 tests if http2 is available
* Fix port in tests to be assigned automatically
* Change http2 test usage to describe.skip if no http2 available
* Fix closing the http2 connections to prevent possible exceptions
* Fix closing the request first, then the client, then the server
* Fix closing for v8.x and v9.x
* fix tests not draining data for http2 requests, resulting in timeouts in node v10.4 onwards
* fix: 🐛 assert.equal error
* fix: 🐛 remove console.log's and timeout, let build fail
* Apply suggestions from code review
Co-authored-by: Lam Wei Li <lam_wei_li@hotmail.com>
* fixed lint
* fix: an issue where test hangs when assertion fails in http2 as http2server is not closed
* refactor: use http2.constants instead of hard-coded strings in http2 test
* Node.js 0.8 compatible
* fix lint issue
---------
Co-authored-by: Moritz Peters <maritz.peters@gmail.com>
Co-authored-by: Moritz Peters <moritz@mpeters.biz>
Co-authored-by: Lam Wei Li <lam_wei_li@hotmail.com>
Co-authored-by: Sebastian Beltran <bjohansebas@gmail.com>