Skip to content

Commit

Permalink
[fix test] Update tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
indexzero committed Aug 22, 2019
1 parent 16d4f8a commit dd1d08b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions test/lib-http-proxy-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -562,8 +562,8 @@ describe('lib/http-proxy.js', function() {
});
});

destiny.on('connection', function (socket) {
expect(socket.upgradeReq.headers['x-special-proxy-header']).to.eql('foobar');
destiny.on('connection', function (socket, upgradeReq) {
expect(upgradeReq.headers['x-special-proxy-header']).to.eql('foobar');

socket.on('message', function (msg) {
expect(msg).to.be('hello there');
Expand Down
2 changes: 1 addition & 1 deletion test/lib-https-proxy-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ describe('lib/http-proxy.js', function() {
proxy.on('error', function (err, req, res) {
expect(err).to.be.an(Error);
if (semver.gt(process.versions.node, '0.12.0')) {
expect(err.toString()).to.be('Error: self signed certificate')
expect(err.toString()).to.be('Error: unable to verify the first certificate')
} else {
expect(err.toString()).to.be('Error: DEPTH_ZERO_SELF_SIGNED_CERT')
}
Expand Down

0 comments on commit dd1d08b

Please sign in to comment.