Add data field in serialization errors (#1100)
* Add data field in serialization errors * Add test for data field in serialization errors Co-authored-by: Tomas Della Vedova <delvedor@users.noreply.github.com>
This commit is contained in:
@ -44,6 +44,7 @@ test('SerializationError', t => {
|
||||
t.true(err instanceof Error)
|
||||
t.true(err instanceof errors.ElasticsearchClientError)
|
||||
t.false(err.hasOwnProperty('meta'))
|
||||
t.true(err.hasOwnProperty('data'))
|
||||
t.end()
|
||||
})
|
||||
|
||||
@ -52,6 +53,7 @@ test('DeserializationError', t => {
|
||||
t.true(err instanceof Error)
|
||||
t.true(err instanceof errors.ElasticsearchClientError)
|
||||
t.false(err.hasOwnProperty('meta'))
|
||||
t.true(err.hasOwnProperty('data'))
|
||||
t.end()
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user