spring-shell
spring-shell copied to clipboard
Carriage return not added
trafficstars
Just before ending a session. I always print the last few lines in the terminal:
protected static void finishInteractiveShell(InteractiveShellSession session, Path outputFile, boolean verify, boolean submit) {
session.write(session.writeSequence().text(outputFile.toString()).cr().build());
session.write(session.writeSequence().text(verify ? "y" : "n").cr().build());
session.write(session.writeSequence().text(submit ? "y" : "n").cr().build());
}
I run my tests in Jenkins and there is around 100 tests. This is flaky and sometimes it breaks as it doesn't add the carriage return after each line of code .cr().
Here is the output in the Jenkins build you can see the two y added at the end of the same line.
? Select an action: [Use arrows to move], filtering 'finish/tmp/junit10400994433265716921/TYPEZTUUTCOLAJ.jsonyy'