LLREST: Wrap at 140 columns (#34489)

Wraps a single line in a test to fit on 140 characters, removing the
only checkstyle suppression for the clients directory.
This commit is contained in:
Nik Everett 2018-10-17 09:17:02 -04:00 committed by GitHub
parent 030e8c8fe3
commit 2cccd4c669
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -46,7 +46,6 @@
<!-- Hopefully temporary suppression of LineLength on files that don't pass it. We should remove these when we the
files start to pass. -->
<suppress files="client[/\\]rest[/\\]src[/\\]test[/\\]java[/\\]org[/\\]elasticsearch[/\\]client[/\\]HeapBufferedAsyncResponseConsumerTests.java" checks="LineLength" />
<suppress files="server[/\\]src[/\\]main[/\\]java[/\\]org[/\\]apache[/\\]lucene[/\\]search[/\\]vectorhighlight[/\\]CustomFieldQuery.java" checks="LineLength" />
<suppress files="server[/\\]src[/\\]main[/\\]java[/\\]org[/\\]elasticsearch[/\\]action[/\\]admin[/\\]cluster[/\\]health[/\\]ClusterHealthRequestBuilder.java" checks="LineLength" />
<suppress files="server[/\\]src[/\\]main[/\\]java[/\\]org[/\\]elasticsearch[/\\]action[/\\]admin[/\\]cluster[/\\]health[/\\]TransportClusterHealthAction.java" checks="LineLength" />

View File

@ -106,7 +106,8 @@ public class HeapBufferedAsyncResponseConsumerTests extends RestClientTestCase {
IllegalAccessException, InvocationTargetException, InstantiationException {
int bufferLimit = randomIntBetween(1, Integer.MAX_VALUE);
//we use reflection to make sure that the class can be instantiated from the outside, and the constructor is public
Constructor<?> constructor = HttpAsyncResponseConsumerFactory.HeapBufferedResponseConsumerFactory.class.getConstructor(Integer.TYPE);
Constructor<?> constructor =
HttpAsyncResponseConsumerFactory.HeapBufferedResponseConsumerFactory.class.getConstructor(Integer.TYPE);
assertEquals(Modifier.PUBLIC, constructor.getModifiers() & Modifier.PUBLIC);
Object object = constructor.newInstance(bufferLimit);
assertThat(object, instanceOf(HttpAsyncResponseConsumerFactory.HeapBufferedResponseConsumerFactory.class));