Fix rest filter tests to expect passthrough when security is disabled

Original commit: elastic/x-pack-elasticsearch@ea6adabb4d
This commit is contained in:
Ryan Ernst 2016-12-02 16:28:18 -08:00
parent dbbf470734
commit 97336ea946
1 changed files with 2 additions and 2 deletions

View File

@ -72,7 +72,7 @@ public class SecurityRestFilterTests extends ESTestCase {
RestRequest request = mock(RestRequest.class);
when(licenseState.isAuthAllowed()).thenReturn(false);
filter.handleRequest(request, channel, null);
verifyZeroInteractions(restHandler);
verify(restHandler).handleRequest(request, channel, null);
verifyZeroInteractions(channel, authcService);
}
@ -98,7 +98,7 @@ public class SecurityRestFilterTests extends ESTestCase {
RestRequest request = mock(RestRequest.class);
when(request.method()).thenReturn(RestRequest.Method.OPTIONS);
filter.handleRequest(request, channel, null);
verifyZeroInteractions(restHandler);
verify(restHandler).handleRequest(request, channel, null);
verifyZeroInteractions(channel);
verifyZeroInteractions(authcService);
}