From c7a12fc31e14225d8c6c3cbd6850c80beda56ff0 Mon Sep 17 00:00:00 2001 From: Chenfei Gao Date: Tue, 26 Mar 2019 14:46:31 -0400 Subject: Fix file access issue in DummyProviderImpl Changed to use ResourceUtils.getResourceAsString in policy/common project to access dummy files. Issue-ID: POLICY-1441 Change-Id: I42d7cb809a0eeedfc2a8a6b82edfe38ad7138548 Signed-off-by: Chenfei Gao --- .../models/tosca/legacy/concepts/LegacyGuardPolicyTest.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'models-tosca/src/test') diff --git a/models-tosca/src/test/java/org/onap/policy/models/tosca/legacy/concepts/LegacyGuardPolicyTest.java b/models-tosca/src/test/java/org/onap/policy/models/tosca/legacy/concepts/LegacyGuardPolicyTest.java index d2b2216e7..764ce063f 100644 --- a/models-tosca/src/test/java/org/onap/policy/models/tosca/legacy/concepts/LegacyGuardPolicyTest.java +++ b/models-tosca/src/test/java/org/onap/policy/models/tosca/legacy/concepts/LegacyGuardPolicyTest.java @@ -23,9 +23,7 @@ package org.onap.policy.models.tosca.legacy.concepts; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; -import java.util.ArrayList; import java.util.HashMap; -import java.util.List; import java.util.Map; import org.junit.Test; @@ -41,10 +39,8 @@ public class LegacyGuardPolicyTest { assertEquals("guard.frequency", guard.getPolicyId()); guard.setPolicyVersion("1"); assertEquals("1", guard.getPolicyVersion()); - Map body = new HashMap<>(); - body.put("actor", "SO"); - List> content = new ArrayList<>(); - content.add(body); + Map content = new HashMap<>(); + content.put("actor", "SO"); guard.setContent(content); assertEquals(1, guard.getContent().size()); } -- cgit 1.2.3-korg