removed the previous browser_yaml_suite, and fixed the 'returns a client' tests

This commit is contained in:
Spencer Alger
2014-01-17 09:45:39 -07:00
parent 3b15f5f309
commit 3d8117ba3e
7 changed files with 8 additions and 285 deletions

View File

@ -46,7 +46,8 @@ describe('Angular esFactory', function () {
return function () {
try {
var client = esFactory({ hosts: null });
expect(client).to.have.keys('ping', 'transport', 'indices', 'cluster');
expect(client).to.have.keys('transport');
expect(client.transport).to.be.a(esFactory.Transport);
client.close();
} catch (e) {
return done(e);

View File

@ -1,5 +1,6 @@
/* jshint browser:true */
var expect = require('expect.js');
var Transport = require('../../../src/lib/transport');
describe('elasticsearch namespace', function () {
var es = window.elasticsearch;
@ -11,7 +12,8 @@ describe('elasticsearch namespace', function () {
});
it('can create a client', function () {
var client = new es.Client({ hosts: null });
expect(client).to.have.keys('ping', 'transport', 'indices', 'cluster');
expect(client).to.have.keys('transport');
expect(client.transport).to.be.a(es.Transport);
client.close();
});
});

View File

@ -1,5 +1,6 @@
/* jshint browser:true */
var expect = require('expect.js');
var Transport = require('../../../src/lib/transport');
describe('jQuery.es namespace', function () {
var $ = window.jQuery;
@ -12,7 +13,8 @@ describe('jQuery.es namespace', function () {
});
it('can create a client', function () {
var client = new $.es.Client({ hosts: null });
expect(client).to.have.keys('ping', 'transport', 'indices', 'cluster');
expect(client).to.have.keys('transport');
expect(client.transport).to.be.a($.es.Transport);
client.close();
});
});