diff options
author | Jim Hahn <jrh3@att.com> | 2019-08-14 17:31:50 -0400 |
---|---|---|
committer | Jim Hahn <jrh3@att.com> | 2019-08-15 11:23:31 -0400 |
commit | 59e9b9a8b56d563814ef21a23716959f772f9194 (patch) | |
tree | f152aea1578a82737501f56916ca07d8e7889d18 /policy-management/src/test/resources | |
parent | a156cf3cbad6512510ae9a02a13c0408f901c734 (diff) |
Fix more sonar issues in drools-pdp
Addressed issues of cyclomatic complexity and deep nesting by
refactoring code into separate methods. In some cases, had to
refactor the code into nested classes to avoid passing too many
parameters to the newly extracted methods.
Addressed issue "too many conditionals" by breaking conditionals
apart.
Addressed issue "Remove usage of generic wildcard type" by eliminating
"? extends" from return values.
Addressed issue "Remove this use of 'Thread.sleep()'" in junit tests
by introducing latches or using Awaitility.
Note: this won't build until ApiUtils has been merged.
Change-Id: I0d5596b4cb918a36bc22f426f426bd238195b458
Issue-ID: POLICY-1968
Signed-off-by: Jim Hahn <jrh3@att.com>
Diffstat (limited to 'policy-management/src/test/resources')
-rw-r--r-- | policy-management/src/test/resources/echo.drl | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/policy-management/src/test/resources/echo.drl b/policy-management/src/test/resources/echo.drl index 664df639..bd26f95b 100644 --- a/policy-management/src/test/resources/echo.drl +++ b/policy-management/src/test/resources/echo.drl @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * ONAP * ================================================================================ - * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2018-2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -20,10 +20,13 @@ package org.onap.policy.drools.test; +import org.onap.policy.drools.controller.internal.MavenDroolsControllerTest; + rule "INIT" lock-on-active when then + MavenDroolsControllerTest.setRunning(); insert(new String("hello,I am up")); end |