File tree Expand file tree Collapse file tree 4 files changed +45
-4
lines changed
elasticsearch-api/spec/elasticsearch/api/actions/searchable_snapshots Expand file tree Collapse file tree 4 files changed +45
-4
lines changed Original file line number Diff line number Diff line change 24
24
url ,
25
25
{ } ,
26
26
nil ,
27
- { }
27
+ { } ,
28
+ { endpoint : 'searchable_snapshots.cache_stats' }
28
29
]
29
30
end
30
31
37
38
context 'when using index' do
38
39
let ( :url ) { '_searchable_snapshots/foo/cache/stats' }
39
40
41
+ let ( :expected_args ) do
42
+ [
43
+ 'GET' ,
44
+ url ,
45
+ { } ,
46
+ nil ,
47
+ { } ,
48
+ { defined_params : { node_id : 'foo' } , endpoint : 'searchable_snapshots.cache_stats' }
49
+ ]
50
+ end
51
+
40
52
it 'performs the request' do
41
53
expect ( client_double . searchable_snapshots . cache_stats ( node_id : 'foo' ) ) . to be_a Elasticsearch ::API ::Response
42
54
end
Original file line number Diff line number Diff line change 24
24
url ,
25
25
{ } ,
26
26
nil ,
27
- { }
27
+ { } ,
28
+ { endpoint : 'searchable_snapshots.clear_cache' }
28
29
]
29
30
end
30
31
37
38
context 'when using index' do
38
39
let ( :url ) { 'foo/_searchable_snapshots/cache/clear' }
39
40
41
+ let ( :expected_args ) do
42
+ [
43
+ 'POST' ,
44
+ url ,
45
+ { } ,
46
+ nil ,
47
+ { } ,
48
+ { defined_params : { index : 'foo' } ,
49
+ endpoint : 'searchable_snapshots.clear_cache' }
50
+ ]
51
+ end
52
+
40
53
it 'performs the request' do
41
54
expect ( client_double . searchable_snapshots . clear_cache ( index : 'foo' ) ) . to be_a Elasticsearch ::API ::Response
42
55
end
Original file line number Diff line number Diff line change 24
24
'_snapshot/foo/bar/_mount' ,
25
25
{ } ,
26
26
{ } ,
27
- { }
27
+ { } ,
28
+ { defined_params : { repository : 'foo' , snapshot : 'bar' } ,
29
+ endpoint : 'searchable_snapshots.mount' }
28
30
]
29
31
end
30
32
Original file line number Diff line number Diff line change 24
24
url ,
25
25
{ } ,
26
26
nil ,
27
- { }
27
+ { } ,
28
+ { endpoint : 'searchable_snapshots.stats' }
28
29
]
29
30
end
31
+
32
+
30
33
let ( :url ) { '_searchable_snapshots/stats' }
31
34
32
35
it 'performs the request' do
36
39
context 'using index' do
37
40
let ( :url ) { 'foo/_searchable_snapshots/stats' }
38
41
42
+ let ( :expected_args ) do
43
+ [
44
+ 'GET' ,
45
+ url ,
46
+ { } ,
47
+ nil ,
48
+ { } ,
49
+ { defined_params : { index : 'foo' } , endpoint : 'searchable_snapshots.stats' }
50
+ ]
51
+ end
52
+
39
53
it 'performs the request' do
40
54
expect ( client_double . searchable_snapshots . stats ( index : 'foo' ) ) . to be_a Elasticsearch ::API ::Response
41
55
end
You can’t perform that action at this time.
0 commit comments