Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make http test suite run http2 compat #20868

Closed
ronag opened this issue May 21, 2018 · 3 comments
Closed

make http test suite run http2 compat #20868

ronag opened this issue May 21, 2018 · 3 comments

Comments

@ronag
Copy link
Member

ronag commented May 21, 2018

I think in theory it should be possible to run the http2 compat code using the http tests. The main thing missing is a http2 compat replacement for http.request. If we have that I believe we could make all the http test run using http2 compat by monkey patching http?

Is this something that would be worth looking into?

Right now we seem to have 2 test suites for testing almost the same things.

@jasnell
Copy link
Member

jasnell commented May 21, 2018

I think it's worth exploring but it's going to be quite difficult to do, I think. Many of the http tests rely on internals that are very different in http2, even with the compat layer, and there are many tests that simply do not translate.

DaAitch added a commit to wildoak/node that referenced this issue May 26, 2018
Simple try refactoring `test/parallel/test-http-request-end.js`
to run with `http` and `http2`.

Refs: nodejs#20868
@DaAitch
Copy link
Contributor

DaAitch commented May 26, 2018

@ronag I agree it would be a cool thing to write one test and test 2 modules. I did a small adaptation of a simple test, and I agree: without a http.request compat it will be hard to do it. I ended up with a very lean impl of http.request just to get the test green.
You can check #dee7447.

@ronag
Copy link
Member Author

ronag commented Dec 28, 2019

Close in favor of #29829

@ronag ronag closed this as completed Dec 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants