Moved get-missing template tests into their own file

This commit is contained in:
Clinton Gormley 2013-09-18 15:29:21 +02:00
parent 853b661789
commit 1eed74c9be
3 changed files with 38 additions and 22 deletions

View File

@ -0,0 +1,17 @@
---
"Get template":
- do:
indices.put_template:
name: test
body:
template: test-*
settings:
number_of_shards: 1
number_of_replicas: 0
- do:
indices.get_template:
name: test
- match: {test.template: "test-*"}
- match: {test.settings: {index.number_of_shards: '1', index.number_of_replicas: '0'}}

View File

@ -0,0 +1,20 @@
---
"Get missing template - post 0.90.3":
- skip:
version: "0 - 0.90.2"
reason: "Missing templates throw 404 from 0.90.3"
- do:
catch: missing
indices.get_template:
name: test
---
"Get missing template - pre 0.90.3":
- skip:
version: "0.90.3 - 999"
reason: "Missing templates didn't throw 404 before 0.90.3"
- do:
indices.get_template:
name: test
- match: {'': {}}

View File

@ -1,5 +1,5 @@
---
"Basic tests for templates":
"Put template":
- do:
indices.put_template:
name: test
@ -17,24 +17,3 @@
- match: {test.template: "test-*"}
- match: {test.settings: {index.number_of_shards: '1', index.number_of_replicas: '0'}}
- do:
indices.delete_template:
name: test
- skip:
version: "0 - 0.90.2"
reason: "Missing templates throw 404 from 0.90.3"
- do:
catch: missing
indices.get_template:
name: test
- skip:
version: "0.90.3 - 999"
reason: "Missing templates didn't throw 404 before 0.90.3"
- do:
indices.get_template:
name: test
- match: {'': {}}