summaryrefslogtreecommitdiffstats
path: root/models-provider/src/test/java
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@est.tech>2019-05-09 20:59:37 +0000
committerliamfallon <liam.fallon@est.tech>2019-05-09 20:59:37 +0000
commit2aea40592eae4b365e69426c8487ff672c18b4e1 (patch)
tree33cd28725d188b38b1c89b9a81f8cbb6ed4fdb9c /models-provider/src/test/java
parent78e05b7c3cf5fa9953eab626f46a45951686cefb (diff)
Store legacy op policy properties as plain strings
THe properties of legacy operational policies are already encoded and should not be stored in JSON format. Issue-ID: POLICY-1759 Change-Id: I3e2a69f216348c02c2ef9c23282f87da52a7f390 Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'models-provider/src/test/java')
-rw-r--r--models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyGuardPersistenceTest.java2
-rw-r--r--models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyOperationalPersistenceTest.java2
2 files changed, 4 insertions, 0 deletions
diff --git a/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyGuardPersistenceTest.java b/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyGuardPersistenceTest.java
index 16956ce0a..c5052dad7 100644
--- a/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyGuardPersistenceTest.java
+++ b/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyGuardPersistenceTest.java
@@ -79,6 +79,8 @@ public class PolicyLegacyGuardPersistenceTest {
*/
@Before
public void setupParameters() throws PfModelException, CoderException {
+ // H2, use "org.mariadb.jdbc.Driver" and "jdbc:mariadb://localhost:3306/policy" for locally installed MariaDB
+
PolicyModelsProviderParameters parameters = new PolicyModelsProviderParameters();
parameters.setDatabaseDriver("org.h2.Driver");
parameters.setDatabaseUrl("jdbc:h2:mem:testdb");
diff --git a/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyOperationalPersistenceTest.java b/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyOperationalPersistenceTest.java
index 1cb64a835..c1cda4d05 100644
--- a/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyOperationalPersistenceTest.java
+++ b/models-provider/src/test/java/org/onap/policy/models/provider/impl/PolicyLegacyOperationalPersistenceTest.java
@@ -79,6 +79,8 @@ public class PolicyLegacyOperationalPersistenceTest {
*/
@Before
public void setupParameters() throws PfModelException, CoderException {
+ // H2, use "org.mariadb.jdbc.Driver" and "jdbc:mariadb://localhost:3306/policy" for locally installed MariaDB
+
PolicyModelsProviderParameters parameters = new PolicyModelsProviderParameters();
parameters.setDatabaseDriver("org.h2.Driver");
parameters.setDatabaseUrl("jdbc:h2:mem:testdb");