Fix naming for abstract test cases

Original commit: elastic/x-pack-elasticsearch@546ac98077
This commit is contained in:
Areek Zillur 2015-09-02 16:58:06 -04:00
parent e4ffceb9ba
commit dc471bc0a9
48 changed files with 95 additions and 107 deletions

View File

@ -27,7 +27,7 @@ import static org.hamcrest.Matchers.*;
/** /**
* a helper class that contains a couple of HTTP helper methods * a helper class that contains a couple of HTTP helper methods
*/ */
public abstract class AbstractPrivilegeTests extends ShieldIntegTestCase { public abstract class AbstractPrivilegeTestCase extends ShieldIntegTestCase {
protected static final String USERS_PASSWD_HASHED = new String(Hasher.BCRYPT.hash(new SecuredString("passwd".toCharArray()))); protected static final String USERS_PASSWD_HASHED = new String(Hasher.BCRYPT.hash(new SecuredString("passwd".toCharArray())));

View File

@ -24,7 +24,7 @@ import static org.elasticsearch.test.ESIntegTestCase.ClusterScope;
import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST; import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST;
@ClusterScope(scope = TEST) @ClusterScope(scope = TEST)
public class ClusterPrivilegeTests extends AbstractPrivilegeTests { public class ClusterPrivilegeTests extends AbstractPrivilegeTestCase {
public static final String ROLES = public static final String ROLES =
"role_a:\n" + "role_a:\n" +

View File

@ -17,7 +17,7 @@ import java.util.Locale;
import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.is;
public class IndexPrivilegeTests extends AbstractPrivilegeTests { public class IndexPrivilegeTests extends AbstractPrivilegeTestCase {
private String jsonDoc = "{ \"name\" : \"elasticsearch\"}"; private String jsonDoc = "{ \"name\" : \"elasticsearch\"}";

View File

@ -16,7 +16,7 @@ import org.elasticsearch.index.query.QueryBuilders;
import org.elasticsearch.plugins.Plugin; import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.watcher.execution.WatchExecutionContext; import org.elasticsearch.watcher.execution.WatchExecutionContext;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.watch.Payload; import org.elasticsearch.watcher.watch.Payload;
@ -36,7 +36,7 @@ import static org.hamcrest.Matchers.is;
/** /**
* *
*/ */
public class ActionErrorIntegrationTests extends AbstractWatcherIntegrationTests { public class ActionErrorIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -13,7 +13,7 @@ import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.history.WatchRecord; import org.elasticsearch.watcher.history.WatchRecord;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.joda.time.DateTimeZone; import org.joda.time.DateTimeZone;
import org.junit.Test; import org.junit.Test;
@ -35,7 +35,7 @@ import static org.hamcrest.Matchers.is;
/** /**
*/ */
public class TimeThrottleIntegrationTests extends AbstractWatcherIntegrationTests { public class TimeThrottleIntegrationTests extends AbstractWatcherIntegrationTestCase {
private IndexResponse indexTestDoc() { private IndexResponse indexTestDoc() {
createIndex("actions", "events"); createIndex("actions", "events");

View File

@ -7,11 +7,10 @@ package org.elasticsearch.watcher.actions.email;
import org.elasticsearch.action.search.SearchRequest; import org.elasticsearch.action.search.SearchRequest;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.watcher.actions.email.service.EmailTemplate; import org.elasticsearch.watcher.actions.email.service.EmailTemplate;
import org.elasticsearch.watcher.actions.email.service.support.EmailServer; import org.elasticsearch.watcher.actions.email.service.support.EmailServer;
import org.elasticsearch.watcher.client.WatcherClient; import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule; import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule;
import org.junit.After; import org.junit.After;
import org.junit.Test; import org.junit.Test;
@ -34,7 +33,7 @@ import static org.hamcrest.Matchers.equalTo;
/** /**
* *
*/ */
public class EmailActionIntegrationTests extends AbstractWatcherIntegrationTests { public class EmailActionIntegrationTests extends AbstractWatcherIntegrationTestCase {
static final String USERNAME = "_user"; static final String USERNAME = "_user";
static final String PASSWORD = "_passwd"; static final String PASSWORD = "_passwd";

View File

@ -8,7 +8,6 @@ package org.elasticsearch.watcher.actions.email;
import org.elasticsearch.action.get.GetResponse; import org.elasticsearch.action.get.GetResponse;
import org.joda.time.DateTime; import org.joda.time.DateTime;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.xcontent.support.XContentMapValues; import org.elasticsearch.common.xcontent.support.XContentMapValues;
import org.elasticsearch.watcher.actions.email.service.EmailTemplate; import org.elasticsearch.watcher.actions.email.service.EmailTemplate;
import org.elasticsearch.watcher.actions.email.service.support.EmailServer; import org.elasticsearch.watcher.actions.email.service.support.EmailServer;
@ -17,7 +16,7 @@ import org.elasticsearch.watcher.execution.ActionExecutionMode;
import org.elasticsearch.watcher.shield.ShieldSecretService; import org.elasticsearch.watcher.shield.ShieldSecretService;
import org.elasticsearch.watcher.support.secret.SecretService; import org.elasticsearch.watcher.support.secret.SecretService;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.trigger.TriggerEvent; import org.elasticsearch.watcher.trigger.TriggerEvent;
@ -43,7 +42,7 @@ import static org.hamcrest.Matchers.*;
/** /**
* *
*/ */
public class EmailSecretsIntegrationTests extends AbstractWatcherIntegrationTests { public class EmailSecretsIntegrationTests extends AbstractWatcherIntegrationTestCase {
static final String USERNAME = "_user"; static final String USERNAME = "_user";
static final String PASSWORD = "_passwd"; static final String PASSWORD = "_passwd";

View File

@ -9,7 +9,7 @@ import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.test.junit.annotations.Network; import org.elasticsearch.test.junit.annotations.Network;
import org.elasticsearch.watcher.actions.hipchat.HipChatAction; import org.elasticsearch.watcher.actions.hipchat.HipChatAction;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -28,7 +28,7 @@ import static org.hamcrest.Matchers.*;
* *
*/ */
@Network @Network
public class HipChatServiceTests extends AbstractWatcherIntegrationTests { public class HipChatServiceTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -14,7 +14,7 @@ import org.elasticsearch.search.SearchHit;
import org.elasticsearch.search.sort.SortOrder; import org.elasticsearch.search.sort.SortOrder;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.support.WatcherDateTimeUtils; import org.elasticsearch.watcher.support.WatcherDateTimeUtils;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent; import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent;
@ -37,7 +37,7 @@ import static org.hamcrest.Matchers.*;
/** /**
* *
*/ */
public class IndexActionIntegrationTests extends AbstractWatcherIntegrationTests { public class IndexActionIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testSimple() throws Exception { public void testSimple() throws Exception {

View File

@ -11,7 +11,7 @@ import org.elasticsearch.test.junit.annotations.Network;
import org.elasticsearch.watcher.actions.slack.SlackAction; import org.elasticsearch.watcher.actions.slack.SlackAction;
import org.elasticsearch.watcher.actions.slack.service.message.Attachment; import org.elasticsearch.watcher.actions.slack.service.message.Attachment;
import org.elasticsearch.watcher.actions.slack.service.message.SlackMessage; import org.elasticsearch.watcher.actions.slack.service.message.SlackMessage;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -30,7 +30,7 @@ import static org.hamcrest.Matchers.*;
* *
*/ */
@Network @Network
public class SlackServiceTests extends AbstractWatcherIntegrationTests { public class SlackServiceTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -23,7 +23,7 @@ import org.elasticsearch.watcher.support.clock.SystemClock;
import org.elasticsearch.watcher.support.http.HttpRequestTemplate; import org.elasticsearch.watcher.support.http.HttpRequestTemplate;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.ObjectPath; import org.elasticsearch.watcher.support.xcontent.ObjectPath;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest; import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest;
import org.elasticsearch.watcher.transport.actions.put.PutWatchRequest; import org.elasticsearch.watcher.transport.actions.put.PutWatchRequest;
@ -50,7 +50,7 @@ import static org.elasticsearch.watcher.trigger.schedule.Schedules.interval;
import static org.hamcrest.Matchers.equalTo; import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.greaterThan; import static org.hamcrest.Matchers.greaterThan;
public class ActionThrottleTests extends AbstractWatcherIntegrationTests { public class ActionThrottleTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testSingleActionAckThrottle() throws Exception { public void testSingleActionAckThrottle() throws Exception {

View File

@ -23,7 +23,7 @@ import org.elasticsearch.watcher.support.http.Scheme;
import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth; import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.junit.After; import org.junit.After;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;
@ -42,7 +42,7 @@ import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.notNullValue; import static org.hamcrest.Matchers.notNullValue;
public class WebhookHttpsIntegrationTests extends AbstractWatcherIntegrationTests { public class WebhookHttpsIntegrationTests extends AbstractWatcherIntegrationTestCase {
private int webPort; private int webPort;
private MockWebServer webServer; private MockWebServer webServer;

View File

@ -21,7 +21,7 @@ import org.elasticsearch.watcher.support.http.HttpRequestTemplate;
import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth; import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.junit.After; import org.junit.After;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;
@ -39,7 +39,7 @@ import static org.hamcrest.Matchers.*;
/** /**
*/ */
public class WebhookIntegrationTests extends AbstractWatcherIntegrationTests { public class WebhookIntegrationTests extends AbstractWatcherIntegrationTestCase {
private int webPort; private int webPort;
private MockWebServer webServer; private MockWebServer webServer;

View File

@ -17,7 +17,7 @@ import org.elasticsearch.search.internal.InternalSearchHits;
import org.elasticsearch.search.internal.InternalSearchResponse; import org.elasticsearch.search.internal.InternalSearchResponse;
import org.elasticsearch.watcher.execution.WatchExecutionContext; import org.elasticsearch.watcher.execution.WatchExecutionContext;
import org.elasticsearch.watcher.support.clock.SystemClock; import org.elasticsearch.watcher.support.clock.SystemClock;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.watch.Payload; import org.elasticsearch.watcher.watch.Payload;
import org.junit.Test; import org.junit.Test;
@ -29,7 +29,7 @@ import static org.mockito.Mockito.when;
/** /**
*/ */
public class CompareConditionSearchTests extends AbstractWatcherIntegrationTests { public class CompareConditionSearchTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testExecute_withAggs() throws Exception { public void testExecute_withAggs() throws Exception {

View File

@ -19,7 +19,7 @@ import org.elasticsearch.threadpool.ThreadPool;
import org.elasticsearch.watcher.execution.WatchExecutionContext; import org.elasticsearch.watcher.execution.WatchExecutionContext;
import org.elasticsearch.watcher.support.Script; import org.elasticsearch.watcher.support.Script;
import org.elasticsearch.watcher.support.init.proxy.ScriptServiceProxy; import org.elasticsearch.watcher.support.init.proxy.ScriptServiceProxy;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.watch.Payload; import org.elasticsearch.watcher.watch.Payload;
import org.junit.After; import org.junit.After;
@ -32,7 +32,7 @@ import static org.mockito.Mockito.when;
/** /**
*/ */
public class ScriptConditionSearchTests extends AbstractWatcherIntegrationTests { public class ScriptConditionSearchTests extends AbstractWatcherIntegrationTestCase {
private ThreadPool tp = null; private ThreadPool tp = null;
private ScriptServiceProxy scriptService; private ScriptServiceProxy scriptService;

View File

@ -21,7 +21,7 @@ import org.elasticsearch.watcher.input.simple.SimpleInput;
import org.elasticsearch.watcher.support.Script; import org.elasticsearch.watcher.support.Script;
import org.elasticsearch.watcher.support.clock.SystemClock; import org.elasticsearch.watcher.support.clock.SystemClock;
import org.elasticsearch.watcher.support.xcontent.ObjectPath; import org.elasticsearch.watcher.support.xcontent.ObjectPath;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequest; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequest;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequestBuilder; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequestBuilder;
@ -66,7 +66,7 @@ import static org.hamcrest.Matchers.not;
import static org.hamcrest.Matchers.notNullValue; import static org.hamcrest.Matchers.notNullValue;
import static org.hamcrest.Matchers.startsWith; import static org.hamcrest.Matchers.startsWith;
public class ManualExecutionTests extends AbstractWatcherIntegrationTests { public class ManualExecutionTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean enableShield() { protected boolean enableShield() {

View File

@ -11,7 +11,7 @@ import org.joda.time.DateTime;
import org.elasticsearch.watcher.condition.ExecutableCondition; import org.elasticsearch.watcher.condition.ExecutableCondition;
import org.elasticsearch.watcher.condition.always.ExecutableAlwaysCondition; import org.elasticsearch.watcher.condition.always.ExecutableAlwaysCondition;
import org.elasticsearch.watcher.input.none.ExecutableNoneInput; import org.elasticsearch.watcher.input.none.ExecutableNoneInput;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent; import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent;
import org.elasticsearch.watcher.watch.Watch; import org.elasticsearch.watcher.watch.Watch;
import org.joda.time.DateTimeZone; import org.joda.time.DateTimeZone;
@ -23,7 +23,7 @@ import static org.hamcrest.Matchers.*;
/** /**
*/ */
public class TriggeredWatchStoreLifeCycleTests extends AbstractWatcherIntegrationTests { public class TriggeredWatchStoreLifeCycleTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testPutLoadUpdate() throws Exception { public void testPutLoadUpdate() throws Exception {

View File

@ -8,7 +8,7 @@ package org.elasticsearch.watcher.execution;
import org.elasticsearch.common.xcontent.ToXContent; import org.elasticsearch.common.xcontent.ToXContent;
import org.elasticsearch.common.xcontent.XContentBuilder; import org.elasticsearch.common.xcontent.XContentBuilder;
import org.elasticsearch.common.xcontent.XContentFactory; import org.elasticsearch.common.xcontent.XContentFactory;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent; import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent;
import org.elasticsearch.watcher.watch.Watch; import org.elasticsearch.watcher.watch.Watch;
@ -20,7 +20,7 @@ import static org.hamcrest.Matchers.equalTo;
/** /**
*/ */
public class TriggeredWatchTests extends AbstractWatcherIntegrationTests { public class TriggeredWatchTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testParser() throws Exception { public void testParser() throws Exception {

View File

@ -10,7 +10,7 @@ import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.test.ESIntegTestCase; import org.elasticsearch.test.ESIntegTestCase;
import org.elasticsearch.test.junit.annotations.TestLogging; import org.elasticsearch.test.junit.annotations.TestLogging;
import org.elasticsearch.watcher.WatcherModule; import org.elasticsearch.watcher.WatcherModule;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.junit.Test; import org.junit.Test;
import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST; import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST;
@ -23,7 +23,7 @@ import static org.hamcrest.core.Is.is;
*/ */
@TestLogging("cluster:DEBUG,action.admin.cluster.settings:DEBUG,watcher:DEBUG") @TestLogging("cluster:DEBUG,action.admin.cluster.settings:DEBUG,watcher:DEBUG")
@ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 1) @ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 1)
public class HistoryStoreSettingsTests extends AbstractWatcherIntegrationTests { public class HistoryStoreSettingsTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testChangeSettings() throws Exception { public void testChangeSettings() throws Exception {

View File

@ -7,13 +7,12 @@ package org.elasticsearch.watcher.history;
import org.elasticsearch.action.search.SearchResponse; import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.search.aggregations.Aggregations; import org.elasticsearch.search.aggregations.Aggregations;
import org.elasticsearch.search.aggregations.bucket.terms.Terms; import org.elasticsearch.search.aggregations.bucket.terms.Terms;
import org.elasticsearch.watcher.actions.email.service.EmailTemplate; import org.elasticsearch.watcher.actions.email.service.EmailTemplate;
import org.elasticsearch.watcher.actions.email.service.support.EmailServer; import org.elasticsearch.watcher.actions.email.service.support.EmailServer;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.After; import org.junit.After;
import org.junit.Test; import org.junit.Test;
@ -33,7 +32,7 @@ import static org.hamcrest.Matchers.notNullValue;
* This test makes sure that the email address fields in the watch_record action result are * This test makes sure that the email address fields in the watch_record action result are
* not analyzed so they can be used in aggregations * not analyzed so they can be used in aggregations
*/ */
public class HistoryTemplateEmailMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateEmailMappingsTests extends AbstractWatcherIntegrationTestCase {
static final String USERNAME = "_user"; static final String USERNAME = "_user";
static final String PASSWORD = "_passwd"; static final String PASSWORD = "_passwd";

View File

@ -13,9 +13,8 @@ import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.search.aggregations.Aggregations; import org.elasticsearch.search.aggregations.Aggregations;
import org.elasticsearch.search.aggregations.bucket.terms.Terms; import org.elasticsearch.search.aggregations.bucket.terms.Terms;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.support.http.HttpRequestTemplate; import org.elasticsearch.watcher.support.http.HttpRequestTemplate;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.After; import org.junit.After;
import org.junit.Before; import org.junit.Before;
@ -38,7 +37,7 @@ import static org.hamcrest.Matchers.notNullValue;
* This test makes sure that the http host and path fields in the watch_record action result are * This test makes sure that the http host and path fields in the watch_record action result are
* not analyzed so they can be used in aggregations * not analyzed so they can be used in aggregations
*/ */
public class HistoryTemplateHttpMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateHttpMappingsTests extends AbstractWatcherIntegrationTestCase {
private int webPort; private int webPort;
private MockWebServer webServer; private MockWebServer webServer;

View File

@ -9,8 +9,7 @@ import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.search.aggregations.Aggregations; import org.elasticsearch.search.aggregations.Aggregations;
import org.elasticsearch.search.aggregations.bucket.terms.Terms; import org.elasticsearch.search.aggregations.bucket.terms.Terms;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -27,7 +26,7 @@ import static org.hamcrest.Matchers.notNullValue;
* This test makes sure that the index action response `index` and `type` fields in the watch_record action result are * This test makes sure that the index action response `index` and `type` fields in the watch_record action result are
* not analyzed so they can be used in aggregations * not analyzed so they can be used in aggregations
*/ */
public class HistoryTemplateIndexActionMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateIndexActionMappingsTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -11,8 +11,7 @@ import org.elasticsearch.action.search.SearchType;
import org.elasticsearch.search.aggregations.Aggregations; import org.elasticsearch.search.aggregations.Aggregations;
import org.elasticsearch.search.aggregations.bucket.terms.Terms; import org.elasticsearch.search.aggregations.bucket.terms.Terms;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -32,7 +31,7 @@ import static org.hamcrest.Matchers.notNullValue;
* This test makes sure that the http host and path fields in the watch_record action result are * This test makes sure that the http host and path fields in the watch_record action result are
* not analyzed so they can be used in aggregations * not analyzed so they can be used in aggregations
*/ */
public class HistoryTemplateSearchInputMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateSearchInputMappingsTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -10,7 +10,7 @@ import org.elasticsearch.action.admin.indices.mapping.get.GetMappingsResponse;
import org.elasticsearch.cluster.metadata.MappingMetaData; import org.elasticsearch.cluster.metadata.MappingMetaData;
import org.elasticsearch.common.collect.ImmutableOpenMap; import org.elasticsearch.common.collect.ImmutableOpenMap;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -30,7 +30,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
* This test makes sure that the different time fields in the watch_record are mapped as date types * This test makes sure that the different time fields in the watch_record are mapped as date types
*/ */
public class HistoryTemplateTimeMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateTimeMappingsTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -10,7 +10,7 @@ import org.elasticsearch.action.admin.indices.mapping.get.GetMappingsResponse;
import org.elasticsearch.cluster.metadata.MappingMetaData; import org.elasticsearch.cluster.metadata.MappingMetaData;
import org.elasticsearch.common.collect.ImmutableOpenMap; import org.elasticsearch.common.collect.ImmutableOpenMap;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -32,7 +32,7 @@ import static org.hamcrest.Matchers.notNullValue;
* This test makes sure that the http host and path fields in the watch_record action result are * This test makes sure that the http host and path fields in the watch_record action result are
* not analyzed so they can be used in aggregations * not analyzed so they can be used in aggregations
*/ */
public class HistoryTemplateTransformMappingsTests extends AbstractWatcherIntegrationTests { public class HistoryTemplateTransformMappingsTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -17,7 +17,7 @@ import org.elasticsearch.watcher.support.http.HttpRequestTemplate;
import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth; import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule; import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule;
import org.junit.Test; import org.junit.Test;
@ -37,7 +37,7 @@ import static org.elasticsearch.watcher.trigger.TriggerBuilders.schedule;
import static org.elasticsearch.watcher.trigger.schedule.Schedules.interval; import static org.elasticsearch.watcher.trigger.schedule.Schedules.interval;
import static org.hamcrest.Matchers.equalTo; import static org.hamcrest.Matchers.equalTo;
public class HttpInputIntegrationTests extends AbstractWatcherIntegrationTests { public class HttpInputIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected Settings nodeSettings(int nodeOrdinal) { protected Settings nodeSettings(int nodeOrdinal) {

View File

@ -7,7 +7,6 @@ package org.elasticsearch.watcher.license;
import com.carrotsearch.randomizedtesting.RandomizedTest; import com.carrotsearch.randomizedtesting.RandomizedTest;
import com.carrotsearch.randomizedtesting.SysGlobals; import com.carrotsearch.randomizedtesting.SysGlobals;
import com.google.common.collect.ImmutableSet;
import org.elasticsearch.ElasticsearchSecurityException; import org.elasticsearch.ElasticsearchSecurityException;
import org.elasticsearch.common.component.AbstractComponent; import org.elasticsearch.common.component.AbstractComponent;
import org.elasticsearch.common.inject.AbstractModule; import org.elasticsearch.common.inject.AbstractModule;
@ -21,7 +20,7 @@ import org.elasticsearch.plugins.Plugin;
import org.elasticsearch.rest.RestStatus; import org.elasticsearch.rest.RestStatus;
import org.elasticsearch.watcher.actions.ActionStatus; import org.elasticsearch.watcher.actions.ActionStatus;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.transport.actions.service.WatcherServiceResponse; import org.elasticsearch.watcher.transport.actions.service.WatcherServiceResponse;
@ -44,7 +43,7 @@ import static org.hamcrest.Matchers.*;
/** /**
* *
*/ */
public class LicenseIntegrationTests extends AbstractWatcherIntegrationTests { public class LicenseIntegrationTests extends AbstractWatcherIntegrationTestCase {
static final License DUMMY_LICENSE = License.builder() static final License DUMMY_LICENSE = License.builder()
.feature(LicenseService.FEATURE_NAME) .feature(LicenseService.FEATURE_NAME)

View File

@ -6,12 +6,9 @@
package org.elasticsearch.watcher.shield; package org.elasticsearch.watcher.shield;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.plugins.PluginsService;
import org.elasticsearch.shield.ShieldPlugin;
import org.elasticsearch.shield.authc.support.SecuredString; import org.elasticsearch.shield.authc.support.SecuredString;
import org.elasticsearch.watcher.WatcherPlugin;
import org.elasticsearch.watcher.WatcherState; import org.elasticsearch.watcher.WatcherState;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
@ -31,7 +28,7 @@ import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.core.Is.is; import static org.hamcrest.core.Is.is;
import static org.joda.time.DateTimeZone.UTC; import static org.joda.time.DateTimeZone.UTC;
public class BasicShieldTests extends AbstractWatcherIntegrationTests { public class BasicShieldTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean enableShield() { protected boolean enableShield() {

View File

@ -10,7 +10,7 @@ import org.elasticsearch.action.search.SearchRequestBuilder;
import org.elasticsearch.action.search.SearchResponse; import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.common.util.Callback; import org.elasticsearch.common.util.Callback;
import org.elasticsearch.watcher.client.WatcherClient; import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule; import org.elasticsearch.watcher.trigger.schedule.IntervalSchedule;
import org.joda.time.format.DateTimeFormat; import org.joda.time.format.DateTimeFormat;
@ -32,7 +32,7 @@ import static org.hamcrest.Matchers.is;
/** /**
*/ */
public class DynamicIndexNameIntegrationTests extends AbstractWatcherIntegrationTests { public class DynamicIndexNameIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -9,7 +9,7 @@ import org.elasticsearch.action.admin.indices.template.get.GetIndexTemplatesResp
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.test.ESIntegTestCase; import org.elasticsearch.test.ESIntegTestCase;
import org.elasticsearch.watcher.WatcherModule; import org.elasticsearch.watcher.WatcherModule;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.junit.Test; import org.junit.Test;
import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST; import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST;
@ -20,7 +20,7 @@ import static org.hamcrest.core.Is.is;
/** /**
*/ */
@ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 1) @ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 1)
public class WatcherIndexTemplateRegistryTests extends AbstractWatcherIntegrationTests { public class WatcherIndexTemplateRegistryTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testTemplates() throws Exception { public void testTemplates() throws Exception {

View File

@ -81,7 +81,7 @@ import static org.hamcrest.core.IsNot.not;
/** /**
*/ */
@ClusterScope(scope = SUITE, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, maxNumDataNodes = 3) @ClusterScope(scope = SUITE, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, maxNumDataNodes = 3)
public abstract class AbstractWatcherIntegrationTests extends ESIntegTestCase { public abstract class AbstractWatcherIntegrationTestCase extends ESIntegTestCase {
private static final boolean timeWarpEnabled = SystemPropertyUtil.getBoolean("tests.timewarp", true); private static final boolean timeWarpEnabled = SystemPropertyUtil.getBoolean("tests.timewarp", true);
@ -287,7 +287,7 @@ public abstract class AbstractWatcherIntegrationTests extends ESIntegTestCase {
return getInstanceFromMaster(TriggerService.class); return getInstanceFromMaster(TriggerService.class);
} }
public AbstractWatcherIntegrationTests() { public AbstractWatcherIntegrationTestCase() {
super(); super();
} }

View File

@ -23,7 +23,7 @@ import org.elasticsearch.watcher.support.WatcherUtils;
import org.elasticsearch.watcher.support.clock.SystemClock; import org.elasticsearch.watcher.support.clock.SystemClock;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
@ -55,7 +55,7 @@ import static org.hamcrest.Matchers.*;
/** /**
*/ */
@TestLogging("watcher.trigger.schedule:TRACE") @TestLogging("watcher.trigger.schedule:TRACE")
public class BasicWatcherTests extends AbstractWatcherIntegrationTests { public class BasicWatcherTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testIndexWatch() throws Exception { public void testIndexWatch() throws Exception {

View File

@ -20,7 +20,7 @@ import org.elasticsearch.watcher.execution.TriggeredWatch;
import org.elasticsearch.watcher.execution.TriggeredWatchStore; import org.elasticsearch.watcher.execution.TriggeredWatchStore;
import org.elasticsearch.watcher.execution.Wid; import org.elasticsearch.watcher.execution.Wid;
import org.elasticsearch.watcher.history.*; import org.elasticsearch.watcher.history.*;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse; import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse;
import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent; import org.elasticsearch.watcher.trigger.schedule.ScheduleTriggerEvent;
import org.elasticsearch.watcher.watch.Watch; import org.elasticsearch.watcher.watch.Watch;
@ -49,7 +49,7 @@ import static org.hamcrest.core.IsEqual.equalTo;
/** /**
*/ */
@TestLogging("watcher:TRACE") @TestLogging("watcher:TRACE")
public class BootStrapTests extends AbstractWatcherIntegrationTests { public class BootStrapTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -5,14 +5,13 @@
*/ */
package org.elasticsearch.watcher.test.integration; package org.elasticsearch.watcher.test.integration;
import com.carrotsearch.randomizedtesting.annotations.Repeat;
import org.elasticsearch.action.search.SearchRequestBuilder; import org.elasticsearch.action.search.SearchRequestBuilder;
import org.elasticsearch.action.search.SearchResponse; import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.common.util.Callback; import org.elasticsearch.common.util.Callback;
import org.elasticsearch.watcher.client.WatcherClient; import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.support.xcontent.ObjectPath; import org.elasticsearch.watcher.support.xcontent.ObjectPath;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -33,7 +32,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
*/ */
public class ExecutionVarsIntegrationTests extends AbstractWatcherIntegrationTests { public class ExecutionVarsIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -20,7 +20,7 @@ import org.elasticsearch.watcher.support.http.auth.basic.ApplicableBasicAuth;
import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth; import org.elasticsearch.watcher.support.http.auth.basic.BasicAuth;
import org.elasticsearch.watcher.support.secret.SecretService; import org.elasticsearch.watcher.support.secret.SecretService;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.trigger.TriggerEvent; import org.elasticsearch.watcher.trigger.TriggerEvent;
@ -49,7 +49,7 @@ import static org.joda.time.DateTimeZone.UTC;
/** /**
* *
*/ */
public class HttpSecretsIntegrationTests extends AbstractWatcherIntegrationTests { public class HttpSecretsIntegrationTests extends AbstractWatcherIntegrationTestCase {
static final String USERNAME = "_user"; static final String USERNAME = "_user";
static final String PASSWORD = "_passwd"; static final String PASSWORD = "_passwd";

View File

@ -27,7 +27,7 @@ import org.elasticsearch.watcher.client.WatchSourceBuilder;
import org.elasticsearch.watcher.client.WatchSourceBuilders; import org.elasticsearch.watcher.client.WatchSourceBuilders;
import org.elasticsearch.watcher.condition.ConditionBuilders; import org.elasticsearch.watcher.condition.ConditionBuilders;
import org.elasticsearch.watcher.execution.ExecutionService; import org.elasticsearch.watcher.execution.ExecutionService;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse; import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse;
@ -53,7 +53,7 @@ import static org.hamcrest.core.Is.is;
@TestLogging("discovery:TRACE,watcher:TRACE") @TestLogging("discovery:TRACE,watcher:TRACE")
@ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 0) @ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 0)
@SuppressLocalMode @SuppressLocalMode
public class NoMasterNodeTests extends AbstractWatcherIntegrationTests { public class NoMasterNodeTests extends AbstractWatcherIntegrationTestCase {
private ClusterDiscoveryConfiguration.UnicastZen config; private ClusterDiscoveryConfiguration.UnicastZen config;

View File

@ -14,7 +14,7 @@ import org.elasticsearch.watcher.execution.ActionExecutionMode;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.support.text.TextTemplate; import org.elasticsearch.watcher.support.text.TextTemplate;
import org.elasticsearch.watcher.support.xcontent.ObjectPath; import org.elasticsearch.watcher.support.xcontent.ObjectPath;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.trigger.TriggerEvent; import org.elasticsearch.watcher.trigger.TriggerEvent;
@ -42,7 +42,7 @@ import static org.hamcrest.Matchers.greaterThan;
/** /**
* *
*/ */
public class WatchMetadataTests extends AbstractWatcherIntegrationTests { public class WatchMetadataTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testWatchMetadata() throws Exception { public void testWatchMetadata() throws Exception {

View File

@ -15,7 +15,7 @@ import org.elasticsearch.node.Node;
import org.elasticsearch.shield.authc.support.SecuredString; import org.elasticsearch.shield.authc.support.SecuredString;
import org.elasticsearch.test.rest.client.http.HttpRequestBuilder; import org.elasticsearch.test.rest.client.http.HttpRequestBuilder;
import org.elasticsearch.test.rest.client.http.HttpResponse; import org.elasticsearch.test.rest.client.http.HttpResponse;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.junit.After; import org.junit.After;
import org.junit.Test; import org.junit.Test;
@ -24,15 +24,15 @@ import java.util.Map;
import static org.elasticsearch.shield.authc.support.UsernamePasswordToken.BASIC_AUTH_HEADER; import static org.elasticsearch.shield.authc.support.UsernamePasswordToken.BASIC_AUTH_HEADER;
import static org.elasticsearch.shield.authc.support.UsernamePasswordToken.basicAuthHeaderValue; import static org.elasticsearch.shield.authc.support.UsernamePasswordToken.basicAuthHeaderValue;
import static org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests.ShieldSettings.TEST_PASSWORD; import static org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase.ShieldSettings.TEST_PASSWORD;
import static org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests.ShieldSettings.TEST_USERNAME; import static org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase.ShieldSettings.TEST_USERNAME;
import static org.hamcrest.CoreMatchers.nullValue; import static org.hamcrest.CoreMatchers.nullValue;
import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.is;
/** /**
* *
*/ */
public class WatcherSettingsFilterTests extends AbstractWatcherIntegrationTests { public class WatcherSettingsFilterTests extends AbstractWatcherIntegrationTestCase {
private CloseableHttpClient httpClient = HttpClients.createDefault(); private CloseableHttpClient httpClient = HttpClients.createDefault();

View File

@ -11,7 +11,7 @@ import org.elasticsearch.common.collect.MapBuilder;
import org.elasticsearch.common.io.Streams; import org.elasticsearch.common.io.Streams;
import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.watcher.support.Script; import org.elasticsearch.watcher.support.Script;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -19,7 +19,6 @@ import org.junit.Test;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.io.OutputStream; import java.io.OutputStream;
import java.net.URISyntaxException;
import java.nio.file.Files; import java.nio.file.Files;
import java.nio.file.Path; import java.nio.file.Path;
@ -39,7 +38,7 @@ import static org.hamcrest.Matchers.*;
/** /**
*/ */
public class TransformIntegrationTests extends AbstractWatcherIntegrationTests { public class TransformIntegrationTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
public Settings nodeSettings(int nodeOrdinal) { public Settings nodeSettings(int nodeOrdinal) {

View File

@ -17,7 +17,7 @@ import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.execution.ExecutionState; import org.elasticsearch.watcher.execution.ExecutionState;
import org.elasticsearch.watcher.history.HistoryStore; import org.elasticsearch.watcher.history.HistoryStore;
import org.elasticsearch.watcher.history.WatchRecord; import org.elasticsearch.watcher.history.WatchRecord;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.ack.AckWatchRequestBuilder; import org.elasticsearch.watcher.transport.actions.ack.AckWatchRequestBuilder;
import org.elasticsearch.watcher.transport.actions.ack.AckWatchResponse; import org.elasticsearch.watcher.transport.actions.ack.AckWatchResponse;
import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest; import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest;
@ -45,7 +45,7 @@ import static org.hamcrest.core.IsEqual.equalTo;
/** /**
*/ */
public class WatchAckTests extends AbstractWatcherIntegrationTests { public class WatchAckTests extends AbstractWatcherIntegrationTestCase {
private IndexResponse indexTestDoc() { private IndexResponse indexTestDoc() {
createIndex("actions", "events"); createIndex("actions", "events");

View File

@ -6,7 +6,7 @@
package org.elasticsearch.watcher.transport.action.delete; package org.elasticsearch.watcher.transport.action.delete;
import org.elasticsearch.action.ActionRequestValidationException; import org.elasticsearch.action.ActionRequestValidationException;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchRequest; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchRequest;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
@ -24,7 +24,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
* *
*/ */
public class DeleteWatchTests extends AbstractWatcherIntegrationTests { public class DeleteWatchTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testDelete() throws Exception { public void testDelete() throws Exception {

View File

@ -7,7 +7,7 @@ package org.elasticsearch.watcher.transport.action.delete;
import org.elasticsearch.test.junit.annotations.TestLogging; import org.elasticsearch.test.junit.annotations.TestLogging;
import org.elasticsearch.watcher.support.Script; import org.elasticsearch.watcher.support.Script;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.elasticsearch.watcher.transport.actions.service.WatcherServiceResponse; import org.elasticsearch.watcher.transport.actions.service.WatcherServiceResponse;
@ -23,7 +23,7 @@ import static org.hamcrest.Matchers.is;
/** /**
*/ */
public class ForceDeleteWatchTests extends AbstractWatcherIntegrationTests { public class ForceDeleteWatchTests extends AbstractWatcherIntegrationTestCase {
//Disable time warping for the force delete long running watch test //Disable time warping for the force delete long running watch test
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -16,7 +16,7 @@ import org.elasticsearch.watcher.execution.ActionExecutionMode;
import org.elasticsearch.watcher.execution.Wid; import org.elasticsearch.watcher.execution.Wid;
import org.elasticsearch.watcher.support.WatcherDateTimeUtils; import org.elasticsearch.watcher.support.WatcherDateTimeUtils;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.ack.AckWatchRequestBuilder; import org.elasticsearch.watcher.transport.actions.ack.AckWatchRequestBuilder;
import org.elasticsearch.watcher.transport.actions.ack.AckWatchResponse; import org.elasticsearch.watcher.transport.actions.ack.AckWatchResponse;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequestBuilder; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchRequestBuilder;
@ -45,7 +45,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
* *
*/ */
public class ExecuteWatchTests extends AbstractWatcherIntegrationTests { public class ExecuteWatchTests extends AbstractWatcherIntegrationTestCase {
@Test(expected = ActionRequestValidationException.class) @Test(expected = ActionRequestValidationException.class)

View File

@ -11,7 +11,7 @@ import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.execution.Wid; import org.elasticsearch.watcher.execution.Wid;
import org.elasticsearch.watcher.support.WatcherDateTimeUtils; import org.elasticsearch.watcher.support.WatcherDateTimeUtils;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse; import org.elasticsearch.watcher.transport.actions.execute.ExecuteWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -28,7 +28,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
* *
*/ */
public class ExecuteWatchWithDateMathTests extends AbstractWatcherIntegrationTests { public class ExecuteWatchWithDateMathTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -7,7 +7,7 @@ package org.elasticsearch.watcher.transport.action.get;
import org.elasticsearch.action.ActionRequestValidationException; import org.elasticsearch.action.ActionRequestValidationException;
import org.elasticsearch.watcher.support.xcontent.XContentSource; import org.elasticsearch.watcher.support.xcontent.XContentSource;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest; import org.elasticsearch.watcher.transport.actions.get.GetWatchRequest;
import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse; import org.elasticsearch.watcher.transport.actions.get.GetWatchResponse;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
@ -27,7 +27,7 @@ import static org.hamcrest.Matchers.nullValue;
/** /**
* *
*/ */
public class GetWatchTests extends AbstractWatcherIntegrationTests { public class GetWatchTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testGet() throws Exception { public void testGet() throws Exception {

View File

@ -9,7 +9,7 @@ package org.elasticsearch.watcher.transport.action.put;
import org.elasticsearch.ElasticsearchParseException; import org.elasticsearch.ElasticsearchParseException;
import org.elasticsearch.action.ActionRequestValidationException; import org.elasticsearch.action.ActionRequestValidationException;
import org.elasticsearch.watcher.client.WatchSourceBuilder; import org.elasticsearch.watcher.client.WatchSourceBuilder;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse; import org.elasticsearch.watcher.transport.actions.put.PutWatchResponse;
import org.junit.Test; import org.junit.Test;
@ -25,7 +25,7 @@ import static org.hamcrest.Matchers.notNullValue;
/** /**
* *
*/ */
public class PutWatchTests extends AbstractWatcherIntegrationTests { public class PutWatchTests extends AbstractWatcherIntegrationTestCase {
@Test @Test

View File

@ -14,7 +14,7 @@ import org.elasticsearch.watcher.condition.ConditionBuilders;
import org.elasticsearch.watcher.execution.ExecutionPhase; import org.elasticsearch.watcher.execution.ExecutionPhase;
import org.elasticsearch.watcher.execution.QueuedWatch; import org.elasticsearch.watcher.execution.QueuedWatch;
import org.elasticsearch.watcher.input.InputBuilders; import org.elasticsearch.watcher.input.InputBuilders;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse; import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsResponse;
import org.joda.time.DateTime; import org.joda.time.DateTime;
import org.junit.Test; import org.junit.Test;
@ -33,7 +33,7 @@ import static org.hamcrest.Matchers.notNullValue;
import static org.hamcrest.Matchers.nullValue; import static org.hamcrest.Matchers.nullValue;
@ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 2) @ESIntegTestCase.ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false, numDataNodes = 2)
public class SlowWatchStatsTests extends AbstractWatcherIntegrationTests { public class SlowWatchStatsTests extends AbstractWatcherIntegrationTestCase {
@Override @Override
protected boolean timeWarped() { protected boolean timeWarped() {

View File

@ -13,7 +13,7 @@ import org.elasticsearch.watcher.WatcherBuild;
import org.elasticsearch.watcher.WatcherState; import org.elasticsearch.watcher.WatcherState;
import org.elasticsearch.watcher.client.WatcherClient; import org.elasticsearch.watcher.client.WatcherClient;
import org.elasticsearch.watcher.condition.ConditionBuilders; import org.elasticsearch.watcher.condition.ConditionBuilders;
import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTests; import org.elasticsearch.watcher.test.AbstractWatcherIntegrationTestCase;
import org.elasticsearch.watcher.test.WatcherTestUtils; import org.elasticsearch.watcher.test.WatcherTestUtils;
import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse; import org.elasticsearch.watcher.transport.actions.delete.DeleteWatchResponse;
import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsRequest; import org.elasticsearch.watcher.transport.actions.stats.WatcherStatsRequest;
@ -38,7 +38,7 @@ import static org.hamcrest.core.IsEqual.equalTo;
*/ */
@ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false) @ClusterScope(scope = TEST, numClientNodes = 0, transportClientRatio = 0, randomDynamicTemplates = false)
@TestLogging("watcher:TRACE") @TestLogging("watcher:TRACE")
public class WatcherStatsTests extends AbstractWatcherIntegrationTests { public class WatcherStatsTests extends AbstractWatcherIntegrationTestCase {
@Test @Test
public void testStartedStats() throws Exception { public void testStartedStats() throws Exception {