Files
opensearch-pyd/test_elasticsearch/test_server/yaml/20_mapping.yaml
T
2013-06-16 16:20:03 +02:00

46 lines
1010 B
YAML

---
"Mapping setup":
- do:
indices.create:
index: test
- do:
indices.put_mapping:
index: test
type: test-type
body:
test-type:
properties:
text:
type: string
---
"Test get mapping retrieves existing mapping":
- do:
indices.get_mapping:
index: test
type: test-type
- is: { test-type.properties.text.type: string }
---
"Test delete mapping removes mapping":
- do:
indices.delete_mapping:
index: test
type: test-type
- do:
indices.get_mapping:
index: test
- length: { test: 0 }
---
"Test type exists":
- do:
indices.exists_type:
index: test
type: test-type
- is: true
---
"Test type doesn't exists":
- do:
indices.exists_type:
index: test
type: not-test-type
- is: false