From 4a698c2e3d926fd69673eea8b15a78bc7770a29c Mon Sep 17 00:00:00 2001 From: Instrumental Date: Fri, 22 Feb 2019 13:52:58 -0600 Subject: Add Multi-Realm class handling Also, improve Logging Issue-ID: AAF-771 Change-Id: I4cf286b5c474596f5e824e5204598cf0c1bb014c Signed-off-by: Instrumental --- shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java') diff --git a/shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java b/shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java index 281f8ad..f49ecb4 100644 --- a/shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java +++ b/shiro/src/test/java/org/onap/aaf/cadi/shiro/test/JU_AAFRealm.java @@ -27,18 +27,20 @@ import org.apache.shiro.authc.UsernamePasswordToken; import org.apache.shiro.authz.AuthorizationInfo; import org.apache.shiro.authz.Permission; import org.apache.shiro.subject.PrincipalCollection; +import org.junit.Test; import org.onap.aaf.cadi.aaf.AAFPermission; +import org.onap.aaf.cadi.config.Config; import org.onap.aaf.cadi.shiro.AAFRealm; import org.onap.aaf.cadi.shiro.AAFShiroPermission; import junit.framework.Assert; public class JU_AAFRealm { -/* - @Test + public void test() { // NOTE This is a live test. This JUnit needs to be built with "Mock" before it can be // an official JUNIT + try { System.setProperty(Config.CADI_PROP_FILES, "/opt/app/osaaf/local/org.onap.aai.props"); TestAAFRealm ar = new TestAAFRealm(); @@ -61,7 +63,7 @@ public class JU_AAFRealm { Assert.fail(); } } - */ + private void testAPerm(boolean expect, AuthorizationInfo azi, String ns, String type, String instance, String action) { AAFShiroPermission testPerm = new AAFShiroPermission(new AAFPermission(ns,type,instance,action,new ArrayList())); -- cgit 1.2.3-korg