Skip to content

Commit

Permalink
Added tests for POST /{alias}/_rollover/{new_index}.
Browse files Browse the repository at this point in the history
Signed-off-by: dblock <[email protected]>
  • Loading branch information
dblock committed Nov 13, 2024
1 parent 067e9c3 commit 9da76e3
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 2 deletions.
29 changes: 29 additions & 0 deletions tests/default/indices/alias/rollover.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
$schema: ../../../../json_schemas/test_story.schema.yaml

description: Test rolling over aliases.
epilogues:
- path: /games
method: DELETE
status: [200, 404]
- path: /rollover
method: DELETE
status: [200, 404]
prologues:
- path: games
method: PUT
- path: /games/_alias/jeux
method: POST
chapters:
- synopsis: Manually roll over an index.
path: /{alias}/_rollover/{new_index}
method: POST
parameters:
alias: jeux
new_index: rollover
response:
status: 200
payload:
acknowledged: true
old_index: games
new_index: rollover
rolled_over: true
5 changes: 3 additions & 2 deletions tests/default/indices/data_stream/rollover.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ prologues:
message: login attempt failed
request_time: '2013-03-01T00:00:00'
epilogues:
- path: /_data_stream/logs-nginx-rollover
method: DELETE
status: [200, 404]
- path: /_data_stream/logs-nginx
method: DELETE
status: [200, 404]
Expand All @@ -30,8 +33,6 @@ epilogues:
status: [200, 404]
chapters:
- synopsis: Manually roll over a data stream.
warnings:
multiple-paths-detected: false
path: /{alias}/_rollover
method: POST
parameters:
Expand Down

0 comments on commit 9da76e3

Please sign in to comment.