diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2021-09-16 22:05:01 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2021-09-16 22:05:01 +0100 |
commit | cc4618c9ba3d974948ebf340b542d8cb01db2f55 (patch) | |
tree | 125ee67bb9e0d548771cf7b61d04bb1f0dc57687 /eclass/python-utils-r1.eclass | |
parent | 677b7ba5c317778df2ad7e70df94b9b7eec4adbc (diff) |
gentoo resync : 16.09.2021
Diffstat (limited to 'eclass/python-utils-r1.eclass')
-rw-r--r-- | eclass/python-utils-r1.eclass | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 4fedf939c779..c729651699dd 100644 --- a/eclass/python-utils-r1.eclass +++ b/eclass/python-utils-r1.eclass @@ -1250,6 +1250,16 @@ build_sphinx() { HTML_DOCS+=( "${dir}/_build/html/." ) } +# @FUNCTION: _python_check_EPYTHON +# @INTERNAL +# @DESCRIPTION: +# Check if EPYTHON is set, die if not. +_python_check_EPYTHON() { + if [[ -z ${EPYTHON} ]]; then + die "EPYTHON unset, invalid call context" + fi +} + # @VARIABLE: EPYTEST_DESELECT # @DEFAULT_UNSET # @DESCRIPTION: @@ -1279,7 +1289,7 @@ build_sphinx() { epytest() { debug-print-function ${FUNCNAME} "${@}" - [[ -n ${EPYTHON} ]] || die "EPYTHON unset, invalid call context" + _python_check_EPYTHON local args=( # verbose progress reporting and tracebacks @@ -1322,7 +1332,7 @@ epytest() { eunittest() { debug-print-function ${FUNCNAME} "${@}" - [[ -n ${EPYTHON} ]] || die "EPYTHON unset, invalid call context" + _python_check_EPYTHON set -- "${EPYTHON}" -m unittest_or_fail discover -v "${@}" |