You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2018/03/21 13:47:18 UTC

syncope git commit: Ignoring test until CXF-7670 gets fixed

Repository: syncope
Updated Branches:
  refs/heads/master 86039f559 -> 1669101c9


Ignoring test until CXF-7670 gets fixed


Project: http://git-wip-us.apache.org/repos/asf/syncope/repo
Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/1669101c
Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/1669101c
Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/1669101c

Branch: refs/heads/master
Commit: 1669101c975e3045b58a561348b5f4f97dba39c5
Parents: 86039f5
Author: Francesco Chicchiriccò <il...@apache.org>
Authored: Wed Mar 21 14:47:07 2018 +0100
Committer: Francesco Chicchiriccò <il...@apache.org>
Committed: Wed Mar 21 14:47:12 2018 +0100

----------------------------------------------------------------------
 .../java/org/apache/syncope/client/cli/SyncopeAdm.java    |  5 +++--
 .../test/java/org/apache/syncope/fit/cli/CLIITCase.java   | 10 +++++-----
 2 files changed, 8 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/syncope/blob/1669101c/client/cli/src/main/java/org/apache/syncope/client/cli/SyncopeAdm.java
----------------------------------------------------------------------
diff --git a/client/cli/src/main/java/org/apache/syncope/client/cli/SyncopeAdm.java b/client/cli/src/main/java/org/apache/syncope/client/cli/SyncopeAdm.java
index 2ececa1..175040e 100644
--- a/client/cli/src/main/java/org/apache/syncope/client/cli/SyncopeAdm.java
+++ b/client/cli/src/main/java/org/apache/syncope/client/cli/SyncopeAdm.java
@@ -19,6 +19,7 @@
 package org.apache.syncope.client.cli;
 
 import javax.ws.rs.ProcessingException;
+import org.apache.commons.lang3.exception.ExceptionUtils;
 import org.apache.syncope.client.cli.commands.AbstractCommand;
 import org.apache.syncope.client.cli.util.CommandUtils;
 import org.slf4j.Logger;
@@ -60,8 +61,8 @@ public final class SyncopeAdm {
             }
         } catch (final ProcessingException e) {
             LOG.error("Error in main", e);
-            RESULT_MANAGER.genericError("Syncope server offline");
-            RESULT_MANAGER.genericError(e.getCause().getMessage());
+            RESULT_MANAGER.genericError("Problems contacting Syncope Server");
+            RESULT_MANAGER.genericError(ExceptionUtils.getMessage(e));
         }
 
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1669101c/fit/core-reference/src/test/java/org/apache/syncope/fit/cli/CLIITCase.java
----------------------------------------------------------------------
diff --git a/fit/core-reference/src/test/java/org/apache/syncope/fit/cli/CLIITCase.java b/fit/core-reference/src/test/java/org/apache/syncope/fit/cli/CLIITCase.java
index ac7339d..d02943e 100644
--- a/fit/core-reference/src/test/java/org/apache/syncope/fit/cli/CLIITCase.java
+++ b/fit/core-reference/src/test/java/org/apache/syncope/fit/cli/CLIITCase.java
@@ -42,6 +42,7 @@ import org.apache.syncope.client.cli.commands.report.ReportCommand;
 import org.apache.syncope.client.cli.commands.role.RoleCommand;
 import org.apache.syncope.client.cli.commands.user.UserCommand;
 import org.apache.syncope.fit.AbstractITCase;
+import org.junit.Ignore;
 import org.junit.jupiter.api.BeforeAll;
 import org.junit.jupiter.api.Test;
 
@@ -165,6 +166,7 @@ public class CLIITCase extends AbstractITCase {
     }
 
     @Test
+    @Ignore("Ignore until CXF-7670 gets fixed")
     public void userRead() {
         final String userKey1 = "1417acbe-cbf6-4277-9372-e75e04f97000";
         final String userKey2 = "74cd8ece-715a-44a4-a736-e17b46c4e7e6";
@@ -178,7 +180,7 @@ public class CLIITCase extends AbstractITCase {
             PROCESS_BUILDER.command(getCommand(
                     new UserCommand().getClass().getAnnotation(Command.class).name(),
                     UserCommand.UserOptions.READ_BY_KEY.getOptionName(),
-                    String.valueOf(userKey1)));
+                    userKey1));
             process1 = PROCESS_BUILDER.start();
             String result = IOUtils.toString(process1.getInputStream(), StandardCharsets.UTF_8);
             assertTrue(result.contains("username: " + userService.read(userKey1).getUsername()));
@@ -186,8 +188,7 @@ public class CLIITCase extends AbstractITCase {
             PROCESS_BUILDER.command(getCommand(
                     new UserCommand().getClass().getAnnotation(Command.class).name(),
                     UserCommand.UserOptions.READ_BY_KEY.getOptionName(),
-                    String.valueOf(userKey1), String.valueOf(userKey2),
-                    String.valueOf(userKey3), String.valueOf(userKey4), String.valueOf(userKey5)));
+                    userKey1, userKey2, userKey3, userKey4, userKey5));
             process2 = PROCESS_BUILDER.start();
             long users = IOUtils.readLines(process2.getInputStream(), StandardCharsets.UTF_8).
                     stream().filter(line -> line.startsWith(" > USER KEY:")).count();
@@ -196,8 +197,7 @@ public class CLIITCase extends AbstractITCase {
             PROCESS_BUILDER.command(getCommand(
                     new UserCommand().getClass().getAnnotation(Command.class).name(),
                     UserCommand.UserOptions.READ_BY_KEY.getOptionName(),
-                    String.valueOf(userKey1), String.valueOf(userKey2),
-                    String.valueOf(userKey3), String.valueOf(userKey4), String.valueOf(userKey5)));
+                    userKey1, userKey2, userKey3, userKey4, userKey5));
             process3 = PROCESS_BUILDER.start();
             String result3 = IOUtils.toString(process3.getInputStream(), StandardCharsets.UTF_8);
             assertTrue(