diff options
author | 2020-09-17 11:22:40 -0400 | |
---|---|---|
committer | 2020-09-17 17:00:15 -0400 | |
commit | 43c4a6ba0fe15350346457d9e8ac2cb4df656b33 (patch) | |
tree | a5dda518526f2dacddb38438709784ce595d9fc3 /ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core | |
parent | 882777cfc554e1eca05d7ba583bc311fd753708b (diff) |
changes in metrics logs
Issue-ID: PORTAL-1008
Change-Id: I007420af6bf5f89862b55b7625f0f2a76d73802f
Signed-off-by: Kishore Reddy Dwaram <kishore.reddy.dwaram@att.com>
Diffstat (limited to 'ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core')
2 files changed, 2 insertions, 35 deletions
diff --git a/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/aspect/EELFLoggerAspectTest.java b/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/aspect/EELFLoggerAspectTest.java index fb3dc079..a81de613 100644 --- a/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/aspect/EELFLoggerAspectTest.java +++ b/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/aspect/EELFLoggerAspectTest.java @@ -93,40 +93,6 @@ public class EELFLoggerAspectTest { } @Test - public void publicMethodTst(){ - eelFLoggerAspect.publicMethod(); - Assert.assertTrue(true); - } - - @Test - public void logMetricsClassAroundTest() throws Throwable { - ProceedingJoinPoint joinPoint = Mockito.mock(ProceedingJoinPoint.class); - MetricsLog mockLog = Mockito.mock(MetricsLog.class); - Signature sign = Mockito.mock(Signature.class); - - Mockito.when(joinPoint.getSignature()).thenReturn(sign); - Mockito.when(sign.getDeclaringType()).thenReturn(getClass()); - Mockito.when(sign.getName()).thenReturn("MethodName"); - - eelFLoggerAspect.logMetricsClassAround(joinPoint, mockLog); - Assert.assertTrue(true); - } - - @Test - public void logMetricsMethodAroundTest() throws Throwable { - ProceedingJoinPoint joinPoint = Mockito.mock(ProceedingJoinPoint.class); - MetricsLog mockLog = Mockito.mock(MetricsLog.class); - Signature sign = Mockito.mock(Signature.class); - - Mockito.when(joinPoint.getSignature()).thenReturn(sign); - Mockito.when(sign.getDeclaringType()).thenReturn(getClass()); - Mockito.when(sign.getName()).thenReturn("MethodName"); - - eelFLoggerAspect.logMetricsMethodAround(joinPoint, mockLog); - Assert.assertTrue(true); - } - - @Test public void performMetricsLoggingTest() { eelFLoggerAspect.performMetricsLogging(); Assert.assertTrue(true); diff --git a/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/logic/EELFLoggerDelegateTest.java b/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/logic/EELFLoggerDelegateTest.java index 322e3c6b..2d1187f9 100644 --- a/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/logic/EELFLoggerDelegateTest.java +++ b/ecomp-sdk/epsdk-core/src/test/java/org/onap/portalsdk/core/logging/logic/EELFLoggerDelegateTest.java @@ -241,7 +241,8 @@ public class EELFLoggerDelegateTest { @Test public void initTest(){ EELFLoggerDelegate eelFLoggerDelegate = new EELFLoggerDelegate(getClass().getName()); - eelFLoggerDelegate.init(SystemProperties.getProperty(SystemProperties.APPLICATION_NAME)); + String appName = "PortalSDK"; + eelFLoggerDelegate.init(appName); Assert.assertTrue(true); } |