add mock client to worker tests
This commit is contained in:
@@ -1,12 +1,18 @@
|
|||||||
import expect from 'expect.js';
|
import expect from 'expect.js';
|
||||||
import { noop } from 'lodash';
|
import { noop } from 'lodash';
|
||||||
import Worker from '../../lib/worker';
|
import Worker from '../../lib/worker';
|
||||||
|
import elasticsearchMock from '../fixtures/elasticsearch';
|
||||||
|
|
||||||
|
|
||||||
describe('Worker class', function () {
|
describe('Worker class', function () {
|
||||||
|
let client;
|
||||||
let mockQueue;
|
let mockQueue;
|
||||||
|
|
||||||
beforeEach(function () {
|
beforeEach(function () {
|
||||||
mockQueue = {};
|
client = new elasticsearchMock.Client();
|
||||||
|
mockQueue = {
|
||||||
|
client: client
|
||||||
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
describe('invalid construction', function () {
|
describe('invalid construction', function () {
|
||||||
|
|||||||
Reference in New Issue
Block a user