aboutsummaryrefslogtreecommitdiffstats
path: root/appc-metric/appc-metric-bundle/src/test
diff options
context:
space:
mode:
authorSandeep J <sandeejh@in.ibm.com>2019-04-11 13:07:14 +0530
committerTakamune Cho <takamune.cho@att.com>2019-04-11 14:41:59 +0000
commit0f19fd0521a0e70ec82fc1676d03546ff4dad8a7 (patch)
treee119885dfa46b5572f9ef4cd98d8574ed8fdd062 /appc-metric/appc-metric-bundle/src/test
parent88431b3f8e57971087c96130bb82ff384a6d9b1e (diff)
added test cases to MetricRegistryImpl.java
to increase code coverage Issue-ID: APPC-1086 Change-Id: I8804c14c88fe0857be7106edd621ee74f4dd1243 Signed-off-by: Sandeep J <sandeejh@in.ibm.com>
Diffstat (limited to 'appc-metric/appc-metric-bundle/src/test')
-rw-r--r--appc-metric/appc-metric-bundle/src/test/java/org/onap/appc/metricservice/impl/MetricRegistryImplTest.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/appc-metric/appc-metric-bundle/src/test/java/org/onap/appc/metricservice/impl/MetricRegistryImplTest.java b/appc-metric/appc-metric-bundle/src/test/java/org/onap/appc/metricservice/impl/MetricRegistryImplTest.java
index 0bde7f7df..ede0e1f16 100644
--- a/appc-metric/appc-metric-bundle/src/test/java/org/onap/appc/metricservice/impl/MetricRegistryImplTest.java
+++ b/appc-metric/appc-metric-bundle/src/test/java/org/onap/appc/metricservice/impl/MetricRegistryImplTest.java
@@ -4,6 +4,8 @@
* ================================================================================
* Copyright (C) 2019 Ericsson
* ================================================================================
+ * Modifications Copyright (C) 2019 IBM.
+ * ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
@@ -29,9 +31,11 @@ import static org.junit.Assert.assertTrue;
import org.junit.Before;
import org.junit.Test;
import org.onap.appc.metricservice.metric.Counter;
+import org.onap.appc.metricservice.metric.MetricBuilderFactory;
import org.onap.appc.metricservice.metric.MetricType;
import org.onap.appc.metricservice.metric.impl.DefaultPrimitiveCounter;
import org.onap.appc.metricservice.metric.impl.DispatchingFuntionMetricImpl;
+import org.onap.appc.metricservice.policy.PolicyBuilderFactory;
public class MetricRegistryImplTest {
@@ -72,5 +76,15 @@ public class MetricRegistryImplTest {
registry.dispose();
assertEquals(0, registry.metrics().length);
}
+
+ @Test
+ public void testmetricBuilderFactory() {
+ assertTrue(registry.metricBuilderFactory() instanceof MetricBuilderFactory);
+ }
+
+ @Test
+ public void testPolicyBuilderFactory() {
+ assertTrue(registry.policyBuilderFactory() instanceof PolicyBuilderFactory);
+ }
}