aboutsummaryrefslogtreecommitdiffstats
path: root/examples/examples-aadm/src/test
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@est.tech>2020-02-25 16:10:08 +0000
committerliamfallon <liam.fallon@est.tech>2020-02-26 08:33:06 +0000
commit35840d835f581c2d61de1c57fe9963e36eb15c9f (patch)
tree10b8a6004cad1b4d1d63ebebe2aa26ae2af7f3e4 /examples/examples-aadm/src/test
parentaacc7442f046d44359934ea3d93f425a809e7616 (diff)
Fix Java 11/Checkstyle/Sonar warnings
A number of Java 11, checkstyle, and SONAR warnings have crept into the Apex codebase over the last number of reviews. This change fixes those issues. Issue-ID: POLICY-1913 Change-Id: I2afd607e80f48323355380fb2fe5e048e18879f9 Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'examples/examples-aadm/src/test')
-rw-r--r--examples/examples-aadm/src/test/java/org/onap/policy/apex/examples/aadm/AadmUseCaseTest.java36
1 files changed, 18 insertions, 18 deletions
diff --git a/examples/examples-aadm/src/test/java/org/onap/policy/apex/examples/aadm/AadmUseCaseTest.java b/examples/examples-aadm/src/test/java/org/onap/policy/apex/examples/aadm/AadmUseCaseTest.java
index b73b98bc4..97f0aeaaa 100644
--- a/examples/examples-aadm/src/test/java/org/onap/policy/apex/examples/aadm/AadmUseCaseTest.java
+++ b/examples/examples-aadm/src/test/java/org/onap/policy/apex/examples/aadm/AadmUseCaseTest.java
@@ -1,7 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2016-2018 Ericsson. All rights reserved.
- * Modifications Copyright (C) 2019 Nordix Foundation.
+ * Modifications Copyright (C) 2019-2020 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -53,7 +53,7 @@ import org.slf4j.ext.XLoggerFactory;
// TODO: Auto-generated Javadoc
/**
* This class tests AADM use case.
- *
+ *
* @author Sergey Sachkov (sergey.sachkov@ericsson.com)
*
*/
@@ -133,9 +133,9 @@ public class AadmUseCaseTest {
// getting number of connections send it to policy, expecting probe action
logger.info("Sending too many connections trigger ");
EnEvent event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 101.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -170,9 +170,9 @@ public class AadmUseCaseTest {
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 101);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 99.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -208,9 +208,9 @@ public class AadmUseCaseTest {
// getting number of connections send it to policy, expecting probe action
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 101.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -243,9 +243,9 @@ public class AadmUseCaseTest {
// tcp correlation return positive dos
logger.info("Receiving action event with {} action", result.get("ACTTASK"));
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("TCP_UE_SIDE_AVG_THROUGHPUT", 101.0);
event.put("ACTTASK", "");
event.put("APPLICATION", "");
@@ -279,9 +279,9 @@ public class AadmUseCaseTest {
// user moving enodeB
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 101.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -313,8 +313,8 @@ public class AadmUseCaseTest {
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
- event.put("ENODEB_ID", new Long(124));
+ event.put("IMSI", Long.valueOf(123456));
+ event.put("ENODEB_ID", Long.valueOf(124));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 101.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -351,9 +351,9 @@ public class AadmUseCaseTest {
// user becomes non anomalous
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
+ event.put("IMSI", Long.valueOf(123456));
event.put("IMSI_IP", "101.111.121.131");
- event.put("ENODEB_ID", new Long(123));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("AVG_SUBSCRIBER_SERVICE_REQUEST", 101.0);
event.put("UE_IP_ADDRESS", "101.111.121.131");
@@ -384,8 +384,8 @@ public class AadmUseCaseTest {
logger.info("Sending too many connections trigger ");
event = apexEngine.createEvent(axEvent.getKey());
- event.put("IMSI", new Long(123456));
- event.put("ENODEB_ID", new Long(123));
+ event.put("IMSI", Long.valueOf(123456));
+ event.put("ENODEB_ID", Long.valueOf(123));
event.put("SERVICE_REQUEST_COUNT", 99);
event.put("UE_IP_ADDRESS", "101.111.121.131");
event.put("ACTTASK", "");