Dobry den, chcel by som sa spytat ci je nutne nejak explicitne menit exit code po zadani --help v list_labels a ak hej, tak ako. Aktualne neprejdem testom, pretoze moj program skonci kodom 3 a nie kodom 0.
There must be standard click help describing options
# and commands (you should write description for each)
#
# Local default config is not required (no token for help is OK)!
#
# It could look like this (help text may differ):
# Usage: labelord.py list_labels [OPTIONS] REPOSITORY
#
# Listing labels of desired repository.
#
# Options:
# --help Show this message and exit.
invocation = invoker_norec('list_labels', '--help', isolated=isolated)
assert invocation.result.exit_code == 0
E assert 3 == 0
E + where 3 = <Result SystemExit(3,)>.exit_code
E + where <Result SystemExit(3,)> = <conftest.LabelordInvocation object at 0x042B7A50>.result
tests\test_run_tricky.py:117: AssertionError
!!!!!!!!!!!!!!!!!!! Interrupted: stopping after 1 failures !!!!!!!!!!!!!!!!!!!!
===================== 1 failed, 64 passed in 2.88 seconds =====================
Dobry den, chcel by som sa spytat ci je nutne nejak explicitne menit exit code po zadani --help v list_labels a ak hej, tak ako. Aktualne neprejdem testom, pretoze moj program skonci kodom 3 a nie kodom 0.
@pytest.mark.parametrize('isolated', [True, False]) def test_help_list_labels(invoker_norec, isolated):
There must be standard click help describing options
tests\test_run_tricky.py:117: AssertionError !!!!!!!!!!!!!!!!!!! Interrupted: stopping after 1 failures !!!!!!!!!!!!!!!!!!!! ===================== 1 failed, 64 passed in 2.88 seconds =====================