summaryrefslogtreecommitdiffstats
path: root/auth/auth-core/src
diff options
context:
space:
mode:
authorInstrumental <jonathan.gathman@att.com>2018-07-19 13:29:32 -0500
committerInstrumental <jonathan.gathman@att.com>2018-07-19 13:29:44 -0500
commit32cdd553a8668e6d03a9cf5b11b360d35a63c87f (patch)
tree48c02e4be820d87efb777d7be20bad57d517b61c /auth/auth-core/src
parent9c8a8b0926b13b07fb1e5394903401e7a3f1ff79 (diff)
Configuration and Auto-Certificates
Issue-ID: AAF-378 Change-Id: Ic820a4e43684a6130f00b28b415a974876099fc3 Signed-off-by: Instrumental <jonathan.gathman@att.com>
Diffstat (limited to 'auth/auth-core/src')
-rw-r--r--auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTrans.java2
-rw-r--r--auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTransImpl.java4
-rw-r--r--auth/auth-core/src/main/java/org/onap/aaf/auth/env/NullTrans.java2
-rw-r--r--auth/auth-core/src/test/java/org/onap/aaf/auth/common/test/JU_Define.java21
4 files changed, 10 insertions, 19 deletions
diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTrans.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTrans.java
index a38a3e20..bd66ff66 100644
--- a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTrans.java
+++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTrans.java
@@ -63,7 +63,7 @@ public interface AuthzTrans extends TransStore {
public abstract void setLur(Lur lur);
- public abstract boolean fish(Permission p);
+ public abstract boolean fish(Permission ... p);
public abstract Organization org();
diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTransImpl.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTransImpl.java
index 2ca8dfd7..ccfd715f 100644
--- a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTransImpl.java
+++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/AuthzTransImpl.java
@@ -166,9 +166,9 @@ public class AuthzTransImpl extends BasicTrans implements AuthzTrans {
}
@Override
- public boolean fish(Permission p) {
+ public boolean fish(Permission ... pond) {
if(lur!=null) {
- return lur.fish(user, p);
+ return lur.fish(user, pond);
}
return false;
}
diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/NullTrans.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/NullTrans.java
index 13f6551b..fb9d628c 100644
--- a/auth/auth-core/src/main/java/org/onap/aaf/auth/env/NullTrans.java
+++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/env/NullTrans.java
@@ -195,7 +195,7 @@ public class NullTrans implements AuthzTrans {
}
@Override
- public boolean fish(Permission p) {
+ public boolean fish(Permission ... p) {
return false;
}
diff --git a/auth/auth-core/src/test/java/org/onap/aaf/auth/common/test/JU_Define.java b/auth/auth-core/src/test/java/org/onap/aaf/auth/common/test/JU_Define.java
index 76e9959c..0f986f24 100644
--- a/auth/auth-core/src/test/java/org/onap/aaf/auth/common/test/JU_Define.java
+++ b/auth/auth-core/src/test/java/org/onap/aaf/auth/common/test/JU_Define.java
@@ -21,32 +21,23 @@
******************************************************************************/
package org.onap.aaf.auth.common.test;
+import static org.mockito.Mockito.mock;
+
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
-import org.junit.Before;
-import static org.mockito.Mockito.*;
-
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Map.Entry;
-import java.util.Set;
-
import org.onap.aaf.auth.common.Define;
import org.onap.aaf.cadi.Access;
import org.onap.aaf.cadi.CadiException;
import org.onap.aaf.cadi.PropAccess;
import org.onap.aaf.cadi.config.Config;
import org.onap.aaf.misc.env.Env;
-import static org.junit.Assert.*;
-
-//import com.att.authz.common.Define;
-import org.powermock.api.mockito.PowerMockito;
import org.powermock.modules.junit4.PowerMockRunner;
@RunWith(PowerMockRunner.class)
public class JU_Define {
+ private static final String AAF_NS_DOT = "AAF_NS.";
public static String ROOT_NS="NS.Not.Set";
public static String ROOT_COMPANY=ROOT_NS;
Access acc;
@@ -62,7 +53,7 @@ public class JU_Define {
@Test
public void testSet() throws CadiException {
PropAccess prop = new PropAccess();
- prop.setProperty("AAF_NS.", "AAF_NS.");
+ prop.setProperty(AAF_NS_DOT, AAF_NS_DOT);
prop.setProperty(Config.AAF_ROOT_NS, ".ns_Test");
prop.setProperty(Config.AAF_ROOT_COMPANY, "company_Test");
Define.set(prop);
@@ -70,7 +61,7 @@ public class JU_Define {
Define.ROOT_COMPANY();
PropAccess prop1 = new PropAccess();
- prop1.setProperty("AAF_NS.", "AAF_NS.");
+ prop1.setProperty(AAF_NS_DOT, AAF_NS_DOT);
prop1.setProperty(Config.AAF_ROOT_NS, ".ns_Test");
Define.set(prop1);
}
@@ -87,7 +78,7 @@ public class JU_Define {
@Test
public void testVarReplace() {
- Define.varReplace("AAF_NS.");
+ Define.varReplace(AAF_NS_DOT);
Define.varReplace("test");
}
}