summaryrefslogtreecommitdiffstats
path: root/authz-cmd/src/test/java
diff options
context:
space:
mode:
Diffstat (limited to 'authz-cmd/src/test/java')
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/JU_AAFCli.java193
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BaseCmd.java235
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BasicAuth.java49
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Help.java92
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Version.java59
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Clear.java63
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Log.java63
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_SessClear.java63
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Admin.java65
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Attrib.java65
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Create.java65
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Delete.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Describe.java73
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListActivity.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListAdminResponsible.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListByName.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListChildren.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListNsKeysByAttrib.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersInRole.java67
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersWithPerm.java67
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Responsible.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Create.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Delete.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Describe.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Grant.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListActivity.java71
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByNS.java71
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByName.java71
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByRole.java71
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByUser.java71
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Rename.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_CreateDelete.java67
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_Describe.java67
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListActivity.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNS.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNameOnly.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByPerm.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByRole.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByUser.java69
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_User.java68
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Cred.java125
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Delg.java81
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListActivity.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListApprovals.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListDelegates.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForCreds.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForPermission.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForRoles.java70
-rw-r--r--authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Role.java68
49 files changed, 0 insertions, 3717 deletions
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_AAFCli.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_AAFCli.java
deleted file mode 100644
index f0057387..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_AAFCli.java
+++ /dev/null
@@ -1,193 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd;
-
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
-import static org.mockito.Mockito.mock;
-
-import java.io.IOException;
-import java.io.OutputStreamWriter;
-import java.net.HttpURLConnection;
-import java.security.GeneralSecurityException;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.authz.env.AuthzEnv;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.Locator;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.cadi.client.PropertyLocator;
-import org.onap.aaf.cadi.config.Config;
-import org.onap.aaf.cadi.config.SecurityInfo;
-import org.onap.aaf.cadi.http.HBasicAuthSS;
-import org.onap.aaf.cadi.http.HMangr;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_AAFCli {
-
- private static AAFcli cli;
- private static int TIMEOUT = Integer.parseInt(Config.AAF_CONN_TIMEOUT_DEF);
-
- @BeforeClass
- public static void setUp() throws Exception, Exception {
- cli = getAAfCli();
- }
-
- @Test
- public void eval() throws Exception {
- assertTrue(cli.eval("#startswith"));
- }
-
- @Test
- public void eval_empty() throws Exception {
- assertTrue(cli.eval(""));
- }
-
- @Test
- public void eval1() throws Exception {
- assertTrue(cli.eval("@[123"));
- }
-
- @Test
- public void eval2() throws Exception {
- assertFalse(cli.eval("as @[ 123"));
- }
-
- @Test
- public void eval3() throws Exception {
- try {
- cli.eval("expect @[ 123");
- } catch (Exception e) {
- // TODO Auto-generated catch block
- assertTrue(e instanceof CadiException);
- }
- }
-
- public void eval31() throws Exception {
- try {
- cli.eval("expect 1 @[ 123");
- } catch (Exception e) {
- // TODO Auto-generated catch block
- assertTrue(e instanceof CadiException);
- }
- }
-
- @Test
- public void eval4() throws Exception {
- try {
- cli.eval("sleep @[ 123");
- } catch (Exception e) {
- assertTrue(e instanceof NumberFormatException);
- }
- }
-
- @Test
- public void eval41() throws Exception {
- assertTrue(cli.eval("sleep 1 @[ 123"));
- }
-
- @Test
- public void eval5() throws Exception {
- try {
- cli.eval("delay @[ 123");
- } catch (Exception e) {
- assertTrue(e instanceof NumberFormatException);
- }
- }
-
- @Test
- public void eval51() throws Exception {
- assertTrue(cli.eval("delay 1 @[ 123"));
- }
-
- @Test
- public void eval7() throws Exception {
- assertFalse(cli.eval("exit @[ 123"));
- }
-
- @Test
- public void eval8() throws Exception {
- assertTrue(cli.eval("REQUEST @[ 123"));
- }
-
- @Test
- public void eval9() throws Exception {
- assertTrue(cli.eval("FORCE @[ 123"));
- }
-
- @Test
- public void eval10() throws Exception {
- assertTrue(cli.eval("set @[ 123"));
- }
-
- @Test
- public void keyboardHelp() throws Exception {
- boolean noError=true;
- try {
- cli.keyboardHelp();
- } catch (Exception e) {
- noError=false;
- }
- assertTrue(noError);
- }
-
-
-
- @Test
- public void setProp() throws Exception {
- boolean noError=true;
- try {
- cli.keyboardHelp();
- } catch (Exception e) {
- noError=false;
- }
- assertTrue(noError);
- }
-
- @Test
- public void eval_randomString() throws Exception {
- assertTrue(cli.eval("Some random string @#&*& to check complete 100 coverage"));
- }
-
- public static AAFcli getAAfCli() throws APIException, LocatorException, GeneralSecurityException, IOException {
- final AuthzEnv env = new AuthzEnv(System.getProperties());
- String aafUrl = "https://DME2RESOLVE";
- SecurityInfo si = new SecurityInfo(env);
- env.loadToSystemPropsStartsWith("AAF", "DME2");
- Locator loc;
- loc = new PropertyLocator(aafUrl);
- TIMEOUT = Integer.parseInt(env.getProperty(Config.AAF_CONN_TIMEOUT, Config.AAF_CONN_TIMEOUT_DEF));
- HMangr hman = new HMangr(env, loc).readTimeout(TIMEOUT).apiVersion("2.0");
-
- // TODO: Consider requiring a default in properties
- env.setProperty(Config.AAF_DEFAULT_REALM,
- System.getProperty(Config.AAF_DEFAULT_REALM, Config.getDefaultRealm()));
- HBasicAuthSS ss = mock(HBasicAuthSS.class);
- return new AAFcli(env, new OutputStreamWriter(System.out), hman, si, ss);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BaseCmd.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BaseCmd.java
deleted file mode 100644
index 2b946512..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BaseCmd.java
+++ /dev/null
@@ -1,235 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-import java.util.Date;
-import java.util.GregorianCalendar;
-
-import javax.xml.datatype.DatatypeConfigurationException;
-import javax.xml.datatype.DatatypeFactory;
-import javax.xml.datatype.XMLGregorianCalendar;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.cadi.client.Future;
-import org.onap.aaf.inno.env.APIException;
-
-import aaf.v2_0.History;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_BaseCmd {
-
- private static AAFcli cli;
- private static BaseCmd bCmd;
-
- @BeforeClass
- public static void setUp() throws APIException, LocatorException, GeneralSecurityException, IOException {
- cli = JU_AAFCli.getAAfCli();
- bCmd = new BaseCmd<>(cli, "testString");
- }
-
- @Test
- public void exec() throws CadiException, APIException, LocatorException {
- assertEquals(bCmd._exec(4, "add", "del", "reset", "extend"), 0);
-
- }
-
- @Test
- public void exec1() throws CadiException, APIException, LocatorException {
- assertEquals(bCmd._exec(0, "add", "del", "reset", "extend"), 0);
-
- }
-
- @Test
- public void error() throws CadiException, APIException, LocatorException {
- boolean noError = true;
- Future<String> future = new Future<String>() {
-
- @Override
- public boolean get(int timeout) throws CadiException {
- // TODO Auto-generated method stub
- return false;
- }
-
- @Override
- public int code() {
- // TODO Auto-generated method stub
- return 0;
- }
-
- @Override
- public String body() {
- // TODO Auto-generated method stub
- return "{%}";
- }
-
- @Override
- public String header(String tag) {
- // TODO Auto-generated method stub
- return null;
- }
- };
- try {
- bCmd.error(future);
- } catch (Exception e) {
- noError = false;
- }
- assertEquals(noError, true);
-
- }
-
-
-
- @Test
- public void activity() throws DatatypeConfigurationException {
- boolean noError = true;
- History history = new History();
- History.Item item = new History.Item();
- item.setTarget("target");
- item.setUser("user");
- item.setMemo("memo");
-
- GregorianCalendar c = new GregorianCalendar();
- c.setTime(new Date());
- XMLGregorianCalendar date = DatatypeFactory.newInstance().newXMLGregorianCalendar(c);
- item.setTimestamp(date);
- history.getItem().add(item);
- try {
- bCmd.activity(history, "history");
- } catch (Exception e) {
- noError = false;
- }
- assertEquals(noError, true);
-
- }
-
- @Test
- public void activity1() throws DatatypeConfigurationException {
- boolean noError = true;
- History history = new History();
- History.Item item = new History.Item();
- item.setTarget("target");
- item.setUser("user");
- item.setMemo("memo");
-
- GregorianCalendar c = new GregorianCalendar();
- c.setTime(new Date());
- XMLGregorianCalendar date = DatatypeFactory.newInstance().newXMLGregorianCalendar(c);
- item.setTimestamp(date);
- history.getItem().add(item);
- try {
- bCmd.activity(history, "1[]");
- } catch (Exception e) {
- noError = false;
- }
- assertEquals(noError, true);
-
- }
-
-
-
- @Test
- public void error1() {
- boolean noError = true;
- Future<String> future = new Future<String>() {
-
- @Override
- public boolean get(int timeout) throws CadiException {
- // TODO Auto-generated method stub
- return false;
- }
-
- @Override
- public int code() {
- // TODO Auto-generated method stub
- return 0;
- }
-
- @Override
- public String body() {
- // TODO Auto-generated method stub
- return "{<html><code>1</code></html>";
- }
-
- @Override
- public String header(String tag) {
- // TODO Auto-generated method stub
- return null;
- }
- };
- try {
- bCmd.error(future);
- } catch (Exception e) {
- noError = false;
- }
- assertEquals(noError, true);
-
- }
-
- @Test
- public void error2() {
- boolean noError = true;
- Future<String> future = new Future<String>() {
-
- @Override
- public boolean get(int timeout) throws CadiException {
- // TODO Auto-generated method stub
- return false;
- }
-
- @Override
- public int code() {
- // TODO Auto-generated method stub
- return 0;
- }
-
- @Override
- public String body() {
- // TODO Auto-generated method stub
- return "other";
- }
-
- @Override
- public String header(String tag) {
- // TODO Auto-generated method stub
- return null;
- }
- };
- try {
- bCmd.error(future);
- } catch (Exception e) {
- noError = false;
- }
- assertEquals(noError, true);
-
- }
-
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BasicAuth.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BasicAuth.java
deleted file mode 100644
index 07f008b6..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_BasicAuth.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.BasicAuth;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_BasicAuth {
-
- @Test
- public void getID () {
- try {
- BasicAuth bAuth = new BasicAuth("testUser", "nopass");
- assertEquals(bAuth.getID(), "testUser");
- System.out.println(bAuth.getID());
- } catch (IOException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
-
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Help.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Help.java
deleted file mode 100644
index f48d71e0..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Help.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.Mock;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.Cmd;
-import org.onap.aaf.cmd.Help;
-
-import com.att.aft.dme2.internal.jetty.http.HttpStatus;
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Help {
-
- private static AAFcli cli;
- private static Help help;
-
- @Mock
- private static List<Cmd> cmds;
-
- @BeforeClass
- public static void setUp() throws APIException, LocatorException, GeneralSecurityException, IOException {
- cli = JU_AAFCli.getAAfCli();
- cmds = new ArrayList<>();
- help = new Help(cli, cmds);
- }
-
- @Test
- public void exec_HTTP_200() {
- try {
- assertEquals(help._exec(1, "helps"), HttpStatus.OK_200);
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
- @Test
- public void exec_HTTP_200_1() {
- try {
- assertEquals(help._exec(1, "helps","help"), HttpStatus.OK_200);
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
- @Test
- public void detailhelp() {
- boolean hasError=false;
- try {
- help.detailedHelp(2, new StringBuilder("detail help test"));
- } catch (Exception e) {
- hasError=true;
- }
- assertEquals(hasError,false);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Version.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Version.java
deleted file mode 100644
index 3bff61b7..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/JU_Version.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.Version;
-
-import com.att.aft.dme2.internal.jetty.http.HttpStatus;
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Version {
-
- private static AAFcli cli;
- private static Version version;
-
- @BeforeClass
- public static void setUp() throws APIException, LocatorException, GeneralSecurityException, IOException {
- cli = JU_AAFCli.getAAfCli();
- version = new Version(cli);
- }
-
- @Test
- public void exec_HTTP_200() throws CadiException, APIException, LocatorException {
- assertEquals(version._exec(0, "Version"), HttpStatus.OK_200);
-
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Clear.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Clear.java
deleted file mode 100644
index 99a2c317..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Clear.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.mgmt;
-
-import static org.mockito.Mockito.mock;
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.mgmt.Clear;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Clear {
-
- private static Clear clr;
-
- @BeforeClass
- public static void setUp() {
- clr = mock(Clear.class);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(clr._exec(0, "clear"), 0);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Log.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Log.java
deleted file mode 100644
index 04a06f0e..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_Log.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.mgmt;
-
-import static org.mockito.Mockito.mock;
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.mgmt.Log;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Log {
-
- private static Log log;
-
- @BeforeClass
- public static void setUp() {
- log = mock(Log.class);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(log._exec(0, "session clear"), 0);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_SessClear.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_SessClear.java
deleted file mode 100644
index 7cda450e..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/mgmt/JU_SessClear.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.mgmt;
-
-import static org.mockito.Mockito.mock;
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.mgmt.SessClear;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_SessClear {
-
- private static SessClear sessclr;
-
- @BeforeClass
- public static void setUp() {
- sessclr = mock(SessClear.class);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(sessclr._exec(0, "session clear"), 0);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Admin.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Admin.java
deleted file mode 100644
index 48cf0958..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Admin.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Admin {
-
- private static Admin admin;
-
- @BeforeClass
- public static void setUp() throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- admin = new Admin(ns);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(admin._exec(0, "add", "del", "reset", "extend"), 500);
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- admin.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Attrib.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Attrib.java
deleted file mode 100644
index 3a03ce65..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Attrib.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Attrib {
-
- private static Attrib attrib;
-
- @BeforeClass
- public static void setUp() throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- attrib = new Attrib(ns);
- }
-
- @Test
- public void exec() {
- try {
- attrib._exec(0, "add", "del", "reset", "extend");
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- attrib.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Create.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Create.java
deleted file mode 100644
index 23034e32..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Create.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Create {
-
- private static Create create;
-
- @BeforeClass
- public static void setUp() throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- create = new Create(ns);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(create._exec(0, "add", "del", "reset", "extend"), 500);
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- create.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Delete.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Delete.java
deleted file mode 100644
index 0d59062d..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Delete.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.inno.env.APIException;
-
-public class JU_Delete {
-
- private static Delete delete;
-
- @BeforeClass
- public static void setUp() throws APIException, LocatorException, GeneralSecurityException, IOException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- delete = new Delete(ns);
-
- }
-
- @Test
- public void exec() {
- try {
- delete._exec(0, "del", "del", "del");
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- delete.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Describe.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Describe.java
deleted file mode 100644
index 1cd7b387..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Describe.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-import static org.mockito.Mockito.CALLS_REAL_METHODS;
-import static org.mockito.Mockito.mock;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.Describe;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Describe {
-
- private static Describe desc;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- desc = new Describe(ns);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(desc._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListActivity.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListActivity.java
deleted file mode 100644
index 16062b8f..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListActivity.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.List;
-import org.onap.aaf.cmd.ns.ListActivity;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListActivity {
-
- private static ListActivity lsActivity;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- lsActivity = new ListActivity(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsActivity._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListAdminResponsible.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListAdminResponsible.java
deleted file mode 100644
index ab28722b..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListAdminResponsible.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.List;
-import org.onap.aaf.cmd.ns.ListAdminResponsible;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListAdminResponsible {
-
- private static ListAdminResponsible lsAdminRes;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- lsAdminRes = new ListAdminResponsible(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsAdminRes._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListByName.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListByName.java
deleted file mode 100644
index effa1d41..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListByName.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.List;
-import org.onap.aaf.cmd.ns.ListByName;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByName {
-
- private static ListByName lsByName;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- lsByName = new ListByName(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByName._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListChildren.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListChildren.java
deleted file mode 100644
index f7a850f4..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListChildren.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.List;
-import org.onap.aaf.cmd.ns.ListChildren;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListChildren {
-
- private static ListChildren lsChildren;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- lsChildren = new ListChildren(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsChildren._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListNsKeysByAttrib.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListNsKeysByAttrib.java
deleted file mode 100644
index 62935a11..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListNsKeysByAttrib.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.ns.List;
-import org.onap.aaf.cmd.ns.ListNsKeysByAttrib;
-import org.onap.aaf.cmd.ns.NS;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListNsKeysByAttrib {
-
- private static ListNsKeysByAttrib lsNsKeys;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- lsNsKeys = new ListNsKeysByAttrib(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsNsKeys._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
-
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersInRole.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersInRole.java
deleted file mode 100644
index 786adb54..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersInRole.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListUsersInRole {
-
- private static ListUsersInRole lsUserinRole;
-
- @BeforeClass
- public static void setUp() throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- ListUsers lsU = new ListUsers(ls);
- lsUserinRole = new ListUsersInRole(lsU);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsUserinRole._exec(0, "add", "del", "reset", "extend"), 500);
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- lsUserinRole.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersWithPerm.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersWithPerm.java
deleted file mode 100644
index 5faa2b7d..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_ListUsersWithPerm.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListUsersWithPerm {
-
- private static ListUsersWithPerm lsUserWithPerm;
-
- @BeforeClass
- public static void setUp() throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- List ls = new List(ns);
- ListUsers lsU = new ListUsers(ls);
- lsUserWithPerm = new ListUsersWithPerm(lsU);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsUserWithPerm._exec(0, "add", "del", "reset", "extend"), 500);
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- lsUserWithPerm.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Responsible.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Responsible.java
deleted file mode 100644
index 89b13fc3..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/ns/JU_Responsible.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.ns;
-
-import static org.junit.Assert.assertEquals;
-
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.inno.env.APIException;
-
-public class JU_Responsible {
-
- private static Responsible responsible;
-
- @BeforeClass
- public static void setUp() throws APIException, LocatorException, GeneralSecurityException, IOException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- NS ns = new NS(cli);
- responsible = new Responsible(ns);
-
- }
-
- @Test
- public void exec1() {
- try {
- responsible._exec(0, "del", "del", "del");
- } catch (Exception e) {
- assertEquals(e.getMessage(), "java.net.UnknownHostException: DME2RESOLVE");
- }
- }
-
- @Test
- public void detailedHelp() {
- boolean hasNoError = true;
- try {
- responsible.detailedHelp(1, new StringBuilder("test"));
- } catch (Exception e) {
- hasNoError = false;
- }
- assertEquals(hasNoError, true);
- }
-
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Create.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Create.java
deleted file mode 100644
index 82c083b5..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Create.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Create;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Create {
-
- private static Create create;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- create = new Create(perm);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(create._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Delete.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Delete.java
deleted file mode 100644
index 21e7e35c..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Delete.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Delete;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Delete {
-
- private static Delete del;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- del = new Delete(perm);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(del._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Describe.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Describe.java
deleted file mode 100644
index d05b44e4..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Describe.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Describe;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Describe {
-
- private static Describe desc;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- desc = new Describe(perm);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(desc._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Grant.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Grant.java
deleted file mode 100644
index a233ca02..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Grant.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Grant;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Grant {
-
- private static Grant grant;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- grant = new Grant(perm);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(grant._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListActivity.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListActivity.java
deleted file mode 100644
index c2712beb..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListActivity.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.List;
-import org.onap.aaf.cmd.perm.ListActivity;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListActivity {
-
- private static ListActivity lsActivity;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- List ls = new List(perm);
- lsActivity = new ListActivity(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsActivity._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByNS.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByNS.java
deleted file mode 100644
index 8935045e..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByNS.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.List;
-import org.onap.aaf.cmd.perm.ListByNS;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByNS {
-
- private static ListByNS lsByNS;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- List ls = new List(perm);
- lsByNS = new ListByNS(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByNS._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByName.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByName.java
deleted file mode 100644
index 3e59d4e6..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByName.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.List;
-import org.onap.aaf.cmd.perm.ListByName;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByName {
-
- private static ListByName lsByName;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- List ls = new List(perm);
- lsByName = new ListByName(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByName._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByRole.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByRole.java
deleted file mode 100644
index d55c0b94..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByRole.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.List;
-import org.onap.aaf.cmd.perm.ListByRole;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByRole {
-
- private static ListByRole lsByRole;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- List ls = new List(perm);
- lsByRole = new ListByRole(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByRole._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByUser.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByUser.java
deleted file mode 100644
index 88fef497..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_ListByUser.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.List;
-import org.onap.aaf.cmd.perm.ListByUser;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByUser {
-
- private static ListByUser lsByName;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- List ls = new List(perm);
- lsByName = new ListByUser(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByName._exec(0, "add","del","reset","extend"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Rename.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Rename.java
deleted file mode 100644
index 6e53e301..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/perm/JU_Rename.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.perm;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.perm.Rename;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Rename {
-
- private static Rename rename;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- Perm perm = new Perm(role);
- rename = new Rename(perm);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(rename._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_CreateDelete.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_CreateDelete.java
deleted file mode 100644
index 92794971..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_CreateDelete.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.CreateDelete;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_CreateDelete {
-
- private static CreateDelete createDel;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- createDel = new CreateDelete(role);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(createDel._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_Describe.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_Describe.java
deleted file mode 100644
index 388b0463..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_Describe.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.Describe;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Describe {
-
- private static Describe desc;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- desc = new Describe(role);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(desc._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListActivity.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListActivity.java
deleted file mode 100644
index 08dc1199..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListActivity.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListActivity;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListActivity {
-
- private static ListActivity lsActivity;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsActivity = new ListActivity(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsActivity._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNS.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNS.java
deleted file mode 100644
index 82133fab..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNS.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListByNS;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByNS {
-
- private static ListByNS lsByNS;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsByNS = new ListByNS(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByNS._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNameOnly.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNameOnly.java
deleted file mode 100644
index 266039aa..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByNameOnly.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListByNameOnly;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByNameOnly {
-
- private static ListByNameOnly lsByName;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsByName = new ListByNameOnly(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByName._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByPerm.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByPerm.java
deleted file mode 100644
index f97a684c..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByPerm.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListByPerm;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByPerm {
-
- private static ListByPerm lsByPerm;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsByPerm = new ListByPerm(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByPerm._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByRole.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByRole.java
deleted file mode 100644
index 0848eb14..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByRole.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListByRole;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByRole {
-
- private static ListByRole lsByRole;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsByRole = new ListByRole(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByRole._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByUser.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByUser.java
deleted file mode 100644
index 17f99812..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_ListByUser.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.role.List;
-import org.onap.aaf.cmd.role.ListByUser;
-import org.onap.aaf.cmd.role.Role;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListByUser {
-
- private static ListByUser lsByUser;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- List ls = new List(role);
- lsByUser = new ListByUser(ls);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsByUser._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_User.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_User.java
deleted file mode 100644
index cadfd941..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/role/JU_User.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.role;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.perm.Perm;
-import org.onap.aaf.cmd.role.Role;
-import org.onap.aaf.cmd.role.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_User {
-
- private static User user;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- Role role = new Role(cli);
- user = new User(role);
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(user._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (APIException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- } catch (LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Cred.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Cred.java
deleted file mode 100644
index aa975936..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Cred.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.when;
-
-import java.io.FileNotFoundException;
-import java.io.PrintWriter;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.Mockito;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.Cmd;
-import org.onap.aaf.cmd.user.Cred;
-import org.onap.aaf.cmd.user.User;
-import org.onap.aaf.authz.env.AuthzEnv;
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Cred {
-
- private static Cred testCred;
- private static User testUser;
- private static AuthzEnv env;
-
-
- @BeforeClass
- public static void setUp() throws FileNotFoundException, APIException {
-
- testCred = mock(Cred.class);
- testUser = mock(User.class);
- env = mock(AuthzEnv.class);
- Mockito.when(env.getProperty(Cmd.STARTDATE,null)).thenReturn(null);
- Mockito.when(env.getProperty(Cmd.ENDDATE,null)).thenReturn(null);
-
- }
-
- @Test
- public void exec() throws CadiException, APIException, LocatorException, FileNotFoundException {
- boolean isNullpointer=false;
- AAFcli aaFcli= new AAFcli(env, new PrintWriter("temp"), null, null, null);
- User user= new User(aaFcli);
- Cred testCred= new Cred(user);
- try {
- testCred._exec(0, "add", "del", "reset", "extend");
- } catch (Exception e) {
- isNullpointer=true;
- }
- assertEquals(isNullpointer, true);
- }
-
-
- @Test
- public void exec_add() {
- try {
- assertNotNull(testCred._exec(0, "zeroed","add","del","reset","extend"));
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
-
- }
-
- @Test
- public void exec_del() {
- try {
- assertNotNull(testCred._exec(1, "zeroed","add","del","reset","extend"));
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
-
- }
-
- @Test
- public void exec_reset() {
- try {
- assertNotNull(testCred._exec(2, "zeroed","add","del","reset","extend"));
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
-
- }
-
- @Test
- public void exec_extend() {
- try {
- assertNotNull(testCred._exec(3, "zeroed","add","del","reset","extend"));
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
-
- }
-
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Delg.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Delg.java
deleted file mode 100644
index 41708466..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Delg.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.mockito.Mockito.mock;
-import static org.junit.Assert.*;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.user.Delg;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Delg {
-
- private static User testUser;
- private static Delg delg;
-
- @BeforeClass
- public static void setUp() throws APIException {
- testUser = mock(User.class);
- delg = mock(Delg.class);
- }
-
- @Test
- public void exec_add() {
- try {
- assertEquals(delg._exec(0, "zero","add","upd","del"), 0);
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
- @Test
- public void exec_upd() {
- try {
- assertEquals(delg._exec(1, "zero","add","upd","del"), 0);
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
- @Test
- public void exec_del() {
- try {
- assertEquals(delg._exec(2, "zero","add","upd","del"), 0);
- } catch (CadiException | APIException | LocatorException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListActivity.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListActivity.java
deleted file mode 100644
index 8edc633b..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListActivity.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListActivity;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListActivity {
-
- private static ListActivity lsActivity;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsActivity = new ListActivity(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsActivity._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListApprovals.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListApprovals.java
deleted file mode 100644
index fe3b91c3..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListApprovals.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListApprovals;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListApprovals {
-
- private static ListApprovals lsApprovals;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsApprovals = new ListApprovals(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsApprovals._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListDelegates.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListDelegates.java
deleted file mode 100644
index e25cedf9..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListDelegates.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListDelegates;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListDelegates {
-
- private static ListDelegates lsDelegates;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsDelegates = new ListDelegates(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsDelegates._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForCreds.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForCreds.java
deleted file mode 100644
index 95012bd0..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForCreds.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListForCreds;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListForCreds {
-
- private static ListForCreds lsForCreds;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsForCreds = new ListForCreds(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsForCreds._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForPermission.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForPermission.java
deleted file mode 100644
index bb1e3dba..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForPermission.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListForPermission;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListForPermission {
-
- private static ListForPermission lsForPermission;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsForPermission = new ListForPermission(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsForPermission._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForRoles.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForRoles.java
deleted file mode 100644
index e2b5cfe6..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_ListForRoles.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.List;
-import org.onap.aaf.cmd.user.ListForRoles;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_ListForRoles {
-
- private static ListForRoles lsForRoles;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- List parent = new List(usr);
- lsForRoles = new ListForRoles(parent);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(lsForRoles._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}
diff --git a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Role.java b/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Role.java
deleted file mode 100644
index 133adf7b..00000000
--- a/authz-cmd/src/test/java/org/onap/aaf/cmd/user/JU_Role.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * ============LICENSE_START====================================================
- * * org.onap.aaf
- * * ===========================================================================
- * * Copyright © 2017 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.
- * * You may obtain a copy of the License at
- * *
- * * http://www.apache.org/licenses/LICENSE-2.0
- * *
- * * Unless required by applicable law or agreed to in writing, software
- * * distributed under the License is distributed on an "AS IS" BASIS,
- * * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * * See the License for the specific language governing permissions and
- * * limitations under the License.
- * * ============LICENSE_END====================================================
- * *
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * *
- ******************************************************************************/
-package org.onap.aaf.cmd.user;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-import org.onap.aaf.cmd.AAFcli;
-import org.onap.aaf.cmd.JU_AAFCli;
-import org.onap.aaf.cmd.user.Role;
-import org.onap.aaf.cmd.user.User;
-
-import org.onap.aaf.cadi.CadiException;
-import org.onap.aaf.cadi.LocatorException;
-import org.onap.aaf.inno.env.APIException;
-
-@RunWith(MockitoJUnitRunner.class)
-public class JU_Role {
-
- private static Role role;
-
- @BeforeClass
- public static void setUp () throws NoSuchFieldException, SecurityException, Exception, IllegalAccessException {
- AAFcli cli = JU_AAFCli.getAAfCli();
- User usr = new User(cli);
- role = new Role(usr);
-
- }
-
- @Test
- public void exec() {
- try {
- assertEquals(role._exec(0, "add","del","reset","extend","clear", "rename", "create"),500);
- } catch (CadiException e) {
-
- e.printStackTrace();
- } catch (APIException e) {
-
- e.printStackTrace();
- } catch (LocatorException e) {
-
- e.printStackTrace();
- }
- }
-}