Commit Graph

67 Commits

Author SHA1 Message Date
6f467bc314 in certain environments (like saucelabs) we can not reliably receive a 0 status code, the error at all will have to be enough for now 2014-02-26 12:44:06 -07:00
f05bde519d added simple helper for properly handling promises in my tests 2014-02-25 09:50:42 -07:00
f389ce7583 reworked the client action tests to ensure that params are not being clobbered in several places, and adjusted the new test to make sure that index is not duplicated in the query params 2014-02-17 10:47:48 -07:00
ed3274547e do not mutate incoming params object 2014-02-17 17:06:44 +01:00
697c761b71 fixed the force closing of the forever agent, which was removing items from the same array it was itterating. 2014-02-17 01:11:53 -07:00
b19f7b7825 Fixed a broken test 2014-02-14 16:29:40 -07:00
76b69b7a9e Use the transport's defer method within the client_action to ensure we use the configured promises everywhere. Allow search requests to be made without any arguments. 2014-02-14 16:03:04 -07:00
03f7a844a3 use lodash-node rather than vanilla lodash so that lodash doesn't attach to require js even when it's available. 2014-02-11 16:08:10 -07:00
257d596207 attempting to diagnos random issues with the client.close() test 2014-02-10 13:49:02 -07:00
1dca382625 turns out 1 second might not be enough 2014-02-07 14:00:05 -07:00
a09c6268a2 on node 0.8 cp.fork does not let the process die when the event loop is empty 2014-02-07 13:39:01 -07:00
327f191056 fixed and added a test for keepalive connection pool forced shutdown 2014-02-06 22:30:29 -07:00
9d1f6067f5 unit tests for the forever-agent change 2014-02-06 14:34:12 -07:00
d5c1d1405c client.ping() requests now set the proper requestTimeout default 2014-02-06 08:48:35 -07:00
7b795fc1a0 removed the requireRoot stuff form the unit tests which need to have vanilla require calls when bundled with browserify 2014-02-05 10:14:59 -07:00
6c5838fbfa Added API generation and Yaml testing for 1.x and 1.0 branches of elasticsearch. 2014-02-05 08:18:19 -07:00
c813307137 remove unused test file 2014-01-30 10:53:18 -07:00
f10052f19e fixed the browser test 2014-01-29 11:31:42 -07:00
513486f372 updated loggers to write the actual url 2014-01-28 16:45:39 -07:00
1d991b47a8 updated mocha-cov dependency to be custom fork that provides valuable information to coveralls, added engine info to package.json, disable styles for codeship, switched to code based pattern that is very specific since the entire es-js repo is stored withing a src directory on codeship 2014-01-22 12:08:22 -07:00
90aa185711 added notes to the API docs regarding the two API versions, and a warning to the config docs. Also updated the client tests to work with the new default 2014-01-17 15:50:06 -07:00
babc7bacea removed pending test to fix saucelabs failures --skip-ci 2014-01-17 15:37:18 -07:00
3d8117ba3e removed the previous browser_yaml_suite, and fixed the 'returns a client' tests 2014-01-17 09:45:39 -07:00
55f3b33dbd Merge pull request #30 from spenceralger/ping_1_0
Stopped overriding the ping method provided by the 1.0 API
2014-01-16 14:45:22 -08:00
b36a6590e8 Stopped overriding the ping method provided by the 1.0 API, but it didn't match the "castExists" regex so...
Fixed the lack of castExists for ping/1.0 by removing castExists all together from the API. It was the
case anyway that all HEAD requests needed to be cast, so now the clientAction module will set that
param when the spec is set to make HEAD requests. The transport.request still expects that parameter.

Switched the apiVersion implementation to use funcEnum, and exposed the options on the Client constructor.
Docs to come.
2014-01-16 15:43:33 -07:00
ab033e9698 added the ability to set a host's host to false, causing the urls it creates to be relative 2014-01-16 14:19:11 -07:00
b3fdf50a94 more attempts to fix the jenkins build 2014-01-16 10:07:36 -07:00
b5105229d3 fixes integration test call on jenkins 2014-01-16 09:58:37 -07:00
a80e6aba4f fixed some doc issues, and reorganized the browser tests. Rather than running one per build, now a unit test page is run, and a build test page is run 2014-01-15 13:09:46 -07:00
4c5426c1b4 added the browser tests 2014-01-15 03:06:56 -07:00
18e134d0a6 Summary of Changes:
- moved es install/start/stop logic into a seperate script
  - `grunt test` now runs the integration tests once for each version of ES we support
  - grunt can now install and run elasticearch (using grunt-run, pure js solution coming later)
  - included seperate es.sh script specifically for starting or stopping elasticsearch
  - url aliases, api, yaml_suite/index.js, and yaml_tests.json, are all now duplicated for 0_90 support
  - the client now accepts an apiVersion argument (undocumented) which defaults to 'master' but can be '0.90'
  - The yaml test runner will now check the name of the ES instance it is connecting to, preventing accidental wiping of ES
2014-01-14 23:10:12 -07:00
37ce4e440c Merge remote-tracking branch 'upstream/master' into browser_tests_for_travis 2014-01-14 17:20:57 -07:00
6de9243fda added tests for #25 2014-01-14 10:48:07 -07:00
3223fb4a6d added browser tests, modified ci script, removed testing for version 0.90.x 2014-01-10 11:23:08 -07:00
3490479eee changes to the testing, incorporating browser_testing 2014-01-09 16:23:02 -07:00
9df9b30aa4 merged lastest changes from master 2014-01-09 16:20:13 -07:00
24906a2c78 after running the file logger tests, get rid of the test.log file. 2014-01-09 15:58:58 -07:00
2aa665c3bc added angular to the scripts, which is sweet\! 2013-12-24 00:52:26 -07:00
6631b19f93 JSON.serialize was still stubbed when testling tries to phone-home about the test result 2013-12-24 00:25:37 -07:00
da80d94bcf fixed a couple test that aimed at 0.8 2013-12-23 18:08:18 -07:00
a77b2be1f2 still working to get the tests running in ie... stupid IE 2013-12-23 17:31:37 -07:00
2b3734a081 switched out assertion library with should.js... I really should have written my own baby util library since that was the third time I've done that... 2013-12-23 15:33:53 -07:00
3d0b2fde4e setup testling 2013-12-23 10:18:52 -07:00
e4f81d6550 updated tests for new promise resolution value 2013-12-22 11:55:36 -07:00
50be1e86b3 Summary of Changes:
- Polished some Grunt config options while testing livereload capabilities in grunt-watch
- tests for connection_pool selection with no living connections
- tests for connection abstract's mini request implementation for ping.
2013-12-18 17:11:32 -07:00
74d3183cc6 Changed the createDefer config param to just be defer 2013-12-17 11:23:16 -07:00
cf3be01c57 - grunt watch will now abort mid task
- connection's ping method now accepts requestTimeout, path, and method params like
  all the grown-up API calls
- ConnectionPool now managed connection timeouts. When a connection dies a
  timeout object is created to track when the timeout is scheduled and the function
  to call when it does. It also tracks how many times it has run to allow the timeout
  to grow
- Timeouts now grow with use of `config.calcDeadTimeout` which is set to 'exponential'
  by default, but can also be set to flat in order to always use the standard
  deadTimeout. Exponential growth of the deadTimeout is stopped at config.maxDeadTimeout
  which is set to 30 minutes by default.
- Connections no longer have a resuscitate method (too hard to spell). Now the
  method is created dynamically as a part of the timeout object as it just calls
  the connection's ping method and needed to access variables like revive attempts.
- Timeouts were moved to the transport layer, meaning that you need to capture the
  abort method and abort the request yourself if you are handling connections
  directly, ConnectionsAbstract's ping method does this.
2013-12-16 02:35:28 -07:00
37cd2f4f6c 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.
2013-12-15 14:12:39 -07:00
dea18fcd7d improved stream mocks for older versions and increased compatabity from 0.8 up 2013-12-12 20:07:31 -07:00
345ac776ef Major updates for testing and grunt, jenkins tests are now powered by the jenkins.sh script in the scripts directory. 2013-12-12 15:39:42 -07:00