1
0

[MINOR] Only log stdout output for non-zero exit from commands in IT (#6199)

This commit is contained in:
Y Ethan Guo
2022-07-24 22:08:33 -07:00
committed by GitHub
parent 76a28daeb0
commit f6e7227ed5

View File

@@ -236,7 +236,9 @@ public abstract class ITTestBase {
int exitCode = dockerClient.inspectExecCmd(createCmdResponse.getId()).exec().getExitCode();
LOG.info("Exit code for command : " + exitCode);
LOG.error("\n\n ###### Stdout #######\n" + callback.getStdout().toString());
if (exitCode != 0) {
LOG.error("\n\n ###### Stdout #######\n" + callback.getStdout().toString());
}
LOG.error("\n\n ###### Stderr #######\n" + callback.getStderr().toString());
if (checkIfSucceed) {