Updated test

This commit is contained in:
delvedor
2018-12-04 14:30:28 +01:00
parent b60a716e00
commit 4b2df7504e
3 changed files with 29 additions and 7 deletions

View File

@ -1,9 +1,20 @@
'use strict'
import { Client, ApiResponse } from '../../index'
import {
Client,
ApiResponse,
EventMeta,
SniffMeta,
events
} from '../../index'
const client = new Client({ node: 'http://localhost:9200' })
client.on(events.REQUEST, (meta: EventMeta) => {})
client.on(events.RESPONSE, (meta: EventMeta) => {})
client.on(events.ERROR, (err: Error, meta: EventMeta) => {})
client.on(events.SNIFF, (err: Error, meta: SniffMeta) => {})
// Callbacks
client.info((err: Error | null, result: ApiResponse) => {})