Skip to content

Commit dd7fd9a

Browse files
authored
Added test for GET /_settings/{name}. (#727)
Signed-off-by: dblock <[email protected]>
1 parent 18f135d commit dd7fd9a

File tree

2 files changed

+58
-34
lines changed

2 files changed

+58
-34
lines changed

tests/default/_core/settings.yaml

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
$schema: ../../../json_schemas/test_story.schema.yaml
2+
3+
description: Test settings.
4+
prologues:
5+
- path: /movies
6+
method: PUT
7+
- path: /movies/_settings
8+
method: PUT
9+
request:
10+
payload:
11+
settings:
12+
index.blocks.write: true
13+
index:
14+
number_of_replicas: 4
15+
epilogues:
16+
- path: /movies
17+
method: DELETE
18+
status: [200, 404]
19+
chapters:
20+
- synopsis: Get settings.
21+
distributions:
22+
excluded:
23+
- amazon-managed
24+
- amazon-serverless
25+
path: /_settings
26+
method: GET
27+
parameters:
28+
allow_no_indices: true
29+
expand_wildcards: all
30+
flat_settings: true
31+
include_defaults: true
32+
ignore_unavailable: true
33+
local: true
34+
response:
35+
status: 200
36+
- synopsis: Get settings (cluster_manager_timeout).
37+
distributions:
38+
excluded:
39+
- amazon-managed
40+
- amazon-serverless
41+
path: /_settings
42+
method: GET
43+
version: '>= 2.0'
44+
parameters:
45+
allow_no_indices: true
46+
expand_wildcards: all
47+
flat_settings: true
48+
include_defaults: true
49+
ignore_unavailable: true
50+
local: true
51+
cluster_manager_timeout: 1s
52+
response:
53+
status: 200
54+
- synopsis: Get settings by name.
55+
path: /_settings/{name}
56+
method: GET
57+
parameters:
58+
name: index.number_of_replicas

tests/default/indices/settings.yaml

-34
Original file line numberDiff line numberDiff line change
@@ -10,40 +10,6 @@ epilogues:
1010
method: DELETE
1111
status: [200, 404]
1212
chapters:
13-
- synopsis: Get global settings.
14-
distributions:
15-
excluded:
16-
- amazon-managed
17-
- amazon-serverless
18-
path: /_settings
19-
method: GET
20-
parameters:
21-
allow_no_indices: true
22-
expand_wildcards: all
23-
flat_settings: true
24-
include_defaults: true
25-
ignore_unavailable: true
26-
local: true
27-
response:
28-
status: 200
29-
- synopsis: Get global settings (cluster_manager_timeout).
30-
distributions:
31-
excluded:
32-
- amazon-managed
33-
- amazon-serverless
34-
path: /_settings
35-
method: GET
36-
version: '>= 2.0'
37-
parameters:
38-
allow_no_indices: true
39-
expand_wildcards: all
40-
flat_settings: true
41-
include_defaults: true
42-
ignore_unavailable: true
43-
local: true
44-
cluster_manager_timeout: 1s
45-
response:
46-
status: 200
4713
- synopsis: Write a setting to an index.
4814
path: /{index}/_settings
4915
method: PUT

0 commit comments

Comments
 (0)