freeipa/ipatests/test_ipatests_plugins
Stanislav Levin 902821e8aa ipatests: Allow zero-length arguments
Currently, such arguments are eaten by 'ipa-run-tests' script as they
are not quoted.

For example, running ipa-run-tests -k ''
results in the actual invocation would be like as:
['/bin/sh',
 '--norc',
 '--noprofile',
 '-c',
 '--',
 "/usr/bin/python3 -c 'import sys,pytest;sys.exit(pytest.main())' -o "
 'cache_dir=/tmp/pytest-of-root/pytest-12/test_ipa_run_tests_empty_expression0/.pytest_cache '
 '--confcutdir=/usr/lib64/python3/site-packages/ipatests -k ']

Note: expressions or marks could be empty as a result of the building
of command line args by more high-level tools, scripts, etc.

So, a short-termed solution is the quotting of zero-length arguments.

Fixes: https://pagure.io/freeipa/issue/8173
Signed-off-by: Stanislav Levin <slev@altlinux.org>
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
2020-02-14 09:29:20 +02:00
..
__init__.py Simplify ipa-run-tests script 2019-07-16 13:23:21 +03:00
test_depr_frameworks.py pytest: Warn about unittest/nose/xunit tests 2020-02-12 18:08:32 +02:00
test_ipa_run_tests.py ipatests: Allow zero-length arguments 2020-02-14 09:29:20 +02:00
test_slicing.py Fix errors found by Pylint-2.4.3 2019-10-21 18:01:32 +11:00