end2end test: refactored http client