aboutsummaryrefslogtreecommitdiffstats
path: root/feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java
diff options
context:
space:
mode:
authoradheli.tavares <adheli.tavares@est.tech>2024-01-09 15:19:07 +0000
committeradheli.tavares <adheli.tavares@est.tech>2024-01-09 16:20:10 +0000
commitcce79248655f484e007769ba81b092148f940d27 (patch)
tree58f493bb4732b7411feb20ddf1c2095d7bf15356 /feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java
parent36d9699056890640daeaa2fef2f2e4d469b433cb (diff)
Drools support for kafka topics
Issue-ID: POLICY-4201 Change-Id: I91676c168c676018aa1079943747f16917f50a49 Signed-off-by: adheli.tavares <adheli.tavares@est.tech>
Diffstat (limited to 'feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java')
-rw-r--r--feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java b/feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java
index d970585b..eb8860d2 100644
--- a/feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java
+++ b/feature-legacy-config/src/test/java/org/onap/policy/drools/legacy/config/LegacyConfigTest.java
@@ -3,6 +3,7 @@
* ONAP
* ================================================================================
* Copyright (C) 2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2024 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -35,6 +36,8 @@ import org.onap.policy.drools.persistence.SystemPersistenceConstants;
public class LegacyConfigTest {
+ private static final String PDPD_CONFIGURATION_TOPIC = "pdpd-configuration";
+
/**
* Set up.
*/
@@ -61,7 +64,7 @@ public class LegacyConfigTest {
assertTrue(config.start());
assertTrue(config.isAlive());
- config.onTopicEvent(Topic.CommInfrastructure.NOOP, "PDPD-CONFIGURATION", "{}");
+ config.onTopicEvent(Topic.CommInfrastructure.NOOP, PDPD_CONFIGURATION_TOPIC, "{}");
assertTrue(config.isAlive());
assertTrue(config.stop());
@@ -75,7 +78,7 @@ public class LegacyConfigTest {
public void testConstructors() {
LegacyConfig config = new LegacyConfig();
assertNotNull(config.getProperties());
- assertEquals("PDPD-CONFIGURATION", config.getSource().getTopic());
+ assertEquals(PDPD_CONFIGURATION_TOPIC, config.getSource().getTopic());
SystemPersistenceConstants.getManager().setConfigurationDir("target/test-classes/bad-properties-1");
assertThatIllegalStateException().isThrownBy(LegacyConfig::new);