If `ClearScrollResponse` implemented `StatusToXContent`, you could add that check to the `status()` method and allow it to be testable in your tests.

You could also possibly use this in the rest action and save some code (like in `RestSearchScrollAction`)

```
client.clearScroll(clearRequest, new RestStatusToXContentListener<ClearScrollResponse>(channel));
```