aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/test/java/org/onap/policy/clamp/clds/it/RobotItCase.java12
-rw-r--r--src/test/resources/robotframework/Dockerfile2
-rw-r--r--src/test/resources/robotframework/tests/02_policy_queries.robot2
3 files changed, 11 insertions, 5 deletions
diff --git a/src/test/java/org/onap/policy/clamp/clds/it/RobotItCase.java b/src/test/java/org/onap/policy/clamp/clds/it/RobotItCase.java
index 2f17c61bf..02e5ee7fa 100644
--- a/src/test/java/org/onap/policy/clamp/clds/it/RobotItCase.java
+++ b/src/test/java/org/onap/policy/clamp/clds/it/RobotItCase.java
@@ -42,6 +42,7 @@ import com.github.dockerjava.core.command.LogContainerResultCallback;
import com.github.dockerjava.netty.NettyDockerCmdExecFactory;
import java.io.File;
import java.util.Objects;
+import org.codehaus.plexus.util.FileUtils;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -99,8 +100,8 @@ public class RobotItCase {
exec = client.inspectContainerCmd(id).exec();
tries++;
} while (exec.getState().getRunning() && tries < TIMEOUT_S);
- Assert.assertEquals(exec.getState().getError(), 0L,
- Objects.requireNonNull(exec.getState().getExitCodeLong()).longValue());
+ logger.info("RobotFramework result:" + exec.getState());
+
LogContainerCmd logContainerCmd = client.logContainerCmd(id);
logContainerCmd.withStdOut(true).withStdErr(true);
try {
@@ -121,5 +122,10 @@ public class RobotItCase {
copyInputStreamToFile(client.copyArchiveFromContainerCmd(id, "/opt/robotframework/reports/report.html").exec(),
new File("target/robotframework/report.html"));
client.stopContainerCmd(id);
+
+ logger.info("RobotFramework output.xml file: " + FileUtils.fileRead("target/robotframework/output.xml"));
+
+ Assert.assertEquals(exec.getState().getError(), 0L,
+ Objects.requireNonNull(exec.getState().getExitCodeLong()).longValue());
}
-}
+} \ No newline at end of file
diff --git a/src/test/resources/robotframework/Dockerfile b/src/test/resources/robotframework/Dockerfile
index 7e0bf8a26..03d180c5e 100644
--- a/src/test/resources/robotframework/Dockerfile
+++ b/src/test/resources/robotframework/Dockerfile
@@ -1,4 +1,4 @@
-FROM ppodgorsek/robot-framework:latest
+FROM ppodgorsek/robot-framework:3.8.0
USER root
COPY requirements.txt .
diff --git a/src/test/resources/robotframework/tests/02_policy_queries.robot b/src/test/resources/robotframework/tests/02_policy_queries.robot
index e62e03476..713a39f52 100644
--- a/src/test/resources/robotframework/tests/02_policy_queries.robot
+++ b/src/test/resources/robotframework/tests/02_policy_queries.robot
@@ -16,6 +16,6 @@ Get Requests policies list ok
${auth} = Create List ${login} ${passw}
Create Session clamp http://localhost:${port} auth=${auth} disable_warnings=1
Set Global Variable ${clamp_session} clamp
- ${response_query}= Get Request ${clamp_session} /restservices/clds/v2/policies/list
+ ${response_query}= Get Request ${clamp_session} /restservices/clds/v2/policies
Should Be Equal As Strings ${response_query.status_code} 200
Should Contain ${response_query.text} ${reponse_pdp_group} \ No newline at end of file