Summary of changes:
- updated copyright - several tempalate changes for the docs - added a config for grunt-contrib-watch - updated nock commit number - fixed the coverage script - removed the export_docs script - added error message for legacy "es" users who don't have a version locked and have not upgraded - host will now add auth to urls created with `#makeUrl()` - Log class no longer looks for `config.loggers` - The log class now properly escapes single quotes in trace logs - Removed compiled yaml_tests.js from the repo - Yaml suite will only log error and warning messages unless the VERBOSE env var is set - createDefer is now a global setting, changed by modifying Transport.createDefer fubction - wrote tests for Content-Type checking - callbacks will now return the body and status of the request (if the request has completed) when an error occurs - Stdio logger now adds "Elasticsearch " to the front of log messages to distinguish it from other output to stdout.
This commit is contained in:
@ -122,8 +122,9 @@ describe('Host class', function () {
|
||||
path: '/this and that',
|
||||
query: {
|
||||
param: 1
|
||||
}
|
||||
}).should.eql('http://localhost:9200/prefix/this and that?param=1&user_id=123');
|
||||
},
|
||||
auth: 'user:pass'
|
||||
}).should.eql('http://user:pass@localhost:9200/prefix/this and that?param=1&user_id=123');
|
||||
});
|
||||
|
||||
it('ensures that path starts with a forward-slash', function () {
|
||||
@ -148,8 +149,8 @@ describe('Host class', function () {
|
||||
host = new Host({ host: 'john', port: 80 });
|
||||
host.makeUrl().should.eql('http://john/');
|
||||
|
||||
host = new Host({ host: 'italy', path: '/pie' });
|
||||
host.makeUrl().should.eql('http://italy:9200/pie');
|
||||
host = new Host({ host: 'italy', path: '/pie', auth: 'user:pass'});
|
||||
host.makeUrl().should.eql('http://user:pass@italy:9200/pie');
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user