Skip to content

Commit

Permalink
feat: Explicitly disallow capture_stdout option on sequence tasks (#265)
Browse files Browse the repository at this point in the history
fix: make test just work for different python versions
  • Loading branch information
nat-n authored Dec 26, 2024
1 parent 3884fcd commit eecbb96
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions tests/test_script_tasks.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import difflib
import sys

no_venv = {"POETRY_VIRTUALENVS_CREATE": "false"}

Expand Down Expand Up @@ -368,16 +367,13 @@ def test_script_with_multi_value_args(run_poe_subproc):
)
assert result.capture == ""
assert result.stdout == ""
if (3, 12, 6) < sys.version_info < (3, 13, 0):
assert (
"poe multiple-value-args: error: argument second: invalid int value: 'dong'"
in result.stderr
)
else:
assert (
"poe multiple-value-args: error: unrecognized arguments: dong"
in result.stderr
)
# accomodate difference in argparse output between python versions
assert (
"poe multiple-value-args: error: argument second: invalid int value: 'dong'"
in result.stderr
) or (
"poe multiple-value-args: error: unrecognized arguments: dong" in result.stderr
)

# wrong type for multiple values
result = run_poe_subproc(
Expand Down

0 comments on commit eecbb96

Please sign in to comment.