diff options
author | GuangrongFu <fu.guangrong@zte.com.cn> | 2019-04-01 17:10:26 +0800 |
---|---|---|
committer | GuangrongFu <fu.guangrong@zte.com.cn> | 2019-04-01 17:26:26 +0800 |
commit | ac5bbbdafffd25bcabca883d8e2542e25fee57a5 (patch) | |
tree | 64cb096e36a9d25c0b0840e28cf198b7b9e82778 /engine-d/src/test/java | |
parent | 7ca609c6fecdb3e6996f12572aedde702bf375c9 (diff) |
Remove Alarm Info from DB when alarms are cleared
Change-Id: If3350d64a6d2a104bc001b433ed98c410b9bb5a9
Issue-ID: HOLMES-204
Signed-off-by: GuangrongFu <fu.guangrong@zte.com.cn>
Diffstat (limited to 'engine-d/src/test/java')
-rw-r--r-- | engine-d/src/test/java/org/onap/holmes/engine/manager/DroolsEngineTest.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/engine-d/src/test/java/org/onap/holmes/engine/manager/DroolsEngineTest.java b/engine-d/src/test/java/org/onap/holmes/engine/manager/DroolsEngineTest.java index 4ad9107..8da4910 100644 --- a/engine-d/src/test/java/org/onap/holmes/engine/manager/DroolsEngineTest.java +++ b/engine-d/src/test/java/org/onap/holmes/engine/manager/DroolsEngineTest.java @@ -17,7 +17,6 @@ package org.onap.holmes.engine.manager;
import org.junit.Before;
-import org.junit.BeforeClass;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
@@ -32,12 +31,11 @@ import org.onap.holmes.engine.wrapper.RuleMgtWrapper; import org.powermock.api.easymock.PowerMock;
import org.powermock.reflect.Whitebox;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.UUID;
import java.util.stream.Collectors;
-import static org.easymock.EasyMock.anyObject;
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.core.IsEqual.equalTo;
import static org.junit.Assert.assertThat;
@@ -295,17 +293,18 @@ class AlarmInfoDaoStub extends AlarmInfoDao { }
@Override
- protected int deleteAlarmByAlarmIsCleared(int alarmIsCleared) {
+ protected int deleteAlarmByAlarmIsCleared(String alarmName, String sourceName, String sourceId) {
return 1;
}
}
class DbDaoUtilStub extends DbDaoUtil {
private AlarmInfoDao dao = new AlarmInfoDaoStub();
+
@Override
public <T> T getJdbiDaoByOnDemand(Class<T> daoClazz) {
- return (T)dao;
+ return (T) dao;
}
}
|