File tree 1 file changed +5
-1
lines changed
client/rest-high-level/src/test/java/org/elasticsearch/client
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 167
167
import static org .hamcrest .CoreMatchers .equalTo ;
168
168
import static org .hamcrest .Matchers .hasEntry ;
169
169
import static org .hamcrest .Matchers .hasKey ;
170
+ import static org .hamcrest .Matchers .is ;
170
171
import static org .hamcrest .Matchers .notNullValue ;
171
172
import static org .hamcrest .Matchers .nullValue ;
172
173
@@ -1958,12 +1959,15 @@ public void testSnapshotsStatus() {
1958
1959
SnapshotsStatusRequest snapshotsStatusRequest = new SnapshotsStatusRequest (repository , snapshots );
1959
1960
setRandomMasterTimeout (snapshotsStatusRequest , expectedParams );
1960
1961
snapshotsStatusRequest .ignoreUnavailable (ignoreUnavailable );
1961
- expectedParams .put ("ignore_unavailable" , Boolean .toString (ignoreUnavailable ));
1962
+ if (ignoreUnavailable ) {
1963
+ expectedParams .put ("ignore_unavailable" , Boolean .toString (true ));
1964
+ }
1962
1965
1963
1966
Request request = RequestConverters .snapshotsStatus (snapshotsStatusRequest );
1964
1967
assertThat (request .getEndpoint (), equalTo (endpoint ));
1965
1968
assertThat (request .getMethod (), equalTo (HttpGet .METHOD_NAME ));
1966
1969
assertThat (request .getParameters (), equalTo (expectedParams ));
1970
+ assertThat (request .getEntity (), is (nullValue ()));
1967
1971
}
1968
1972
1969
1973
public void testDeleteSnapshot () {
You can’t perform that action at this time.
0 commit comments