To examine an exception in rest tests, the exception should be caught, not ignored
This commit is contained in:
parent
e5f99e0bde
commit
5b3c662145
|
@ -26,13 +26,13 @@
|
||||||
reason: validation logic only fixed from 5.1.2 onwards
|
reason: validation logic only fixed from 5.1.2 onwards
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
|
catch: request
|
||||||
create:
|
create:
|
||||||
index: test
|
index: test
|
||||||
type: test
|
type: test
|
||||||
id: 3
|
id: 3
|
||||||
body: { foo: bar }
|
body: { foo: bar }
|
||||||
version: 5
|
version: 5
|
||||||
ignore: 400
|
|
||||||
|
|
||||||
- match: { status: 400 }
|
- match: { status: 400 }
|
||||||
- match: { error.type: action_request_validation_exception }
|
- match: { error.type: action_request_validation_exception }
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
reason: validation logic only fixed from 5.1.2 onwards
|
reason: validation logic only fixed from 5.1.2 onwards
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
|
catch: request
|
||||||
create:
|
create:
|
||||||
index: test
|
index: test
|
||||||
type: test
|
type: test
|
||||||
|
@ -13,13 +14,13 @@
|
||||||
body: { foo: bar }
|
body: { foo: bar }
|
||||||
version_type: external
|
version_type: external
|
||||||
version: 0
|
version: 0
|
||||||
ignore: 400
|
|
||||||
|
|
||||||
- match: { status: 400 }
|
- match: { status: 400 }
|
||||||
- match: { error.type: action_request_validation_exception }
|
- match: { error.type: action_request_validation_exception }
|
||||||
- match: { error.reason: "Validation Failed: 1: create operations only support internal versioning. use index instead;" }
|
- match: { error.reason: "Validation Failed: 1: create operations only support internal versioning. use index instead;" }
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
|
catch: request
|
||||||
create:
|
create:
|
||||||
index: test
|
index: test
|
||||||
type: test
|
type: test
|
||||||
|
@ -27,7 +28,6 @@
|
||||||
body: { foo: bar }
|
body: { foo: bar }
|
||||||
version_type: external
|
version_type: external
|
||||||
version: 5
|
version: 5
|
||||||
ignore: 400
|
|
||||||
|
|
||||||
- match: { status: 400 }
|
- match: { status: 400 }
|
||||||
- match: { error.type: action_request_validation_exception }
|
- match: { error.type: action_request_validation_exception }
|
||||||
|
|
|
@ -106,9 +106,9 @@ setup:
|
||||||
version: " - 5.0.99"
|
version: " - 5.0.99"
|
||||||
reason: strict stats handling does not exist in 5.0
|
reason: strict stats handling does not exist in 5.0
|
||||||
- do:
|
- do:
|
||||||
|
catch: request
|
||||||
indices.stats:
|
indices.stats:
|
||||||
metric: [ fieldata ]
|
metric: [ fieldata ]
|
||||||
ignore: 400
|
|
||||||
|
|
||||||
- match: { status: 400 }
|
- match: { status: 400 }
|
||||||
- match: { error.type: illegal_argument_exception }
|
- match: { error.type: illegal_argument_exception }
|
||||||
|
|
|
@ -27,9 +27,9 @@
|
||||||
version: " - 5.0.99"
|
version: " - 5.0.99"
|
||||||
reason: strict stats handling does not exist in 5.0
|
reason: strict stats handling does not exist in 5.0
|
||||||
- do:
|
- do:
|
||||||
|
catch: request
|
||||||
nodes.stats:
|
nodes.stats:
|
||||||
metric: [ transprot ]
|
metric: [ transprot ]
|
||||||
ignore: 400
|
|
||||||
|
|
||||||
- match: { status: 400 }
|
- match: { status: 400 }
|
||||||
- match: { error.type: illegal_argument_exception }
|
- match: { error.type: illegal_argument_exception }
|
||||||
|
|
Loading…
Reference in New Issue