Search in sources :

Example 1 with HTTPAlarmCallback

use of org.graylog2.alarmcallbacks.HTTPAlarmCallback in project graylog2-server by Graylog2.

the class HTTPAlarmCallbackTest method setUp.

@Before
public void setUp() throws Exception {
    httpClient = new OkHttpClient();
    objectMapper = new ObjectMapperProvider().get();
    whitelistService = mock(UrlWhitelistService.class);
    alarmCallback = new HTTPAlarmCallback(httpClient, objectMapper, whitelistService);
    server = new MockWebServer();
}
Also used : OkHttpClient(okhttp3.OkHttpClient) MockWebServer(okhttp3.mockwebserver.MockWebServer) ObjectMapperProvider(org.graylog2.shared.bindings.providers.ObjectMapperProvider) UrlWhitelistService(org.graylog2.system.urlwhitelist.UrlWhitelistService) Before(org.junit.Before)

Aggregations

OkHttpClient (okhttp3.OkHttpClient)1 MockWebServer (okhttp3.mockwebserver.MockWebServer)1 ObjectMapperProvider (org.graylog2.shared.bindings.providers.ObjectMapperProvider)1 UrlWhitelistService (org.graylog2.system.urlwhitelist.UrlWhitelistService)1 Before (org.junit.Before)1