Skip to content

Commit

Permalink
openjdk:17 started printing jshell> to stderr
Browse files Browse the repository at this point in the history
We therefore just concatenate stdout & stderr as we really just want to check
whether the output is there.
  • Loading branch information
dcermak committed Jul 31, 2023
1 parent 8242468 commit ef3e895
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/test_openjdk_devel.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,12 @@ def test_entrypoint(container, java_version, host, container_runtime):
:command:`jshell`.
"""
intro = host.run_expect(
cmd = host.run_expect(
[0],
f"{container_runtime.runner_binary} run --rm {container.image_url_or_id}",
).stdout
)
# openjdk 17 prints the "jshell>" to stderr
intro = cmd.stdout + cmd.stderr

assert "jshell>" in intro
assert f"Welcome to JShell -- Version {java_version}" in intro
Expand Down

0 comments on commit ef3e895

Please sign in to comment.