Skip to content

Commit

Permalink
Added test for GET /_settings/{name}. (#727)
Browse files Browse the repository at this point in the history
Signed-off-by: dblock <[email protected]>
  • Loading branch information
dblock authored Dec 12, 2024
1 parent 18f135d commit dd7fd9a
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 34 deletions.
58 changes: 58 additions & 0 deletions tests/default/_core/settings.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
$schema: ../../../json_schemas/test_story.schema.yaml

description: Test settings.
prologues:
- path: /movies
method: PUT
- path: /movies/_settings
method: PUT
request:
payload:
settings:
index.blocks.write: true
index:
number_of_replicas: 4
epilogues:
- path: /movies
method: DELETE
status: [200, 404]
chapters:
- synopsis: Get settings.
distributions:
excluded:
- amazon-managed
- amazon-serverless
path: /_settings
method: GET
parameters:
allow_no_indices: true
expand_wildcards: all
flat_settings: true
include_defaults: true
ignore_unavailable: true
local: true
response:
status: 200
- synopsis: Get settings (cluster_manager_timeout).
distributions:
excluded:
- amazon-managed
- amazon-serverless
path: /_settings
method: GET
version: '>= 2.0'
parameters:
allow_no_indices: true
expand_wildcards: all
flat_settings: true
include_defaults: true
ignore_unavailable: true
local: true
cluster_manager_timeout: 1s
response:
status: 200
- synopsis: Get settings by name.
path: /_settings/{name}
method: GET
parameters:
name: index.number_of_replicas
34 changes: 0 additions & 34 deletions tests/default/indices/settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,40 +10,6 @@ epilogues:
method: DELETE
status: [200, 404]
chapters:
- synopsis: Get global settings.
distributions:
excluded:
- amazon-managed
- amazon-serverless
path: /_settings
method: GET
parameters:
allow_no_indices: true
expand_wildcards: all
flat_settings: true
include_defaults: true
ignore_unavailable: true
local: true
response:
status: 200
- synopsis: Get global settings (cluster_manager_timeout).
distributions:
excluded:
- amazon-managed
- amazon-serverless
path: /_settings
method: GET
version: '>= 2.0'
parameters:
allow_no_indices: true
expand_wildcards: all
flat_settings: true
include_defaults: true
ignore_unavailable: true
local: true
cluster_manager_timeout: 1s
response:
status: 200
- synopsis: Write a setting to an index.
path: /{index}/_settings
method: PUT
Expand Down

0 comments on commit dd7fd9a

Please sign in to comment.