mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-07 05:57:07 -08:00
python-utils-r1.eclass: Cleanup cache dirs after epytest
Make epytest clean up common cache directories .hypothesis
and .pytest_cache after the execution. If pytest is executed
in ${BUILD_DIR}/lib, these directories end up being wrongly installed,
and so far ebuilds had to handle cleaning them up.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
@@ -1272,7 +1272,12 @@ epytest() {
|
||||
|
||||
echo "${@}" >&2
|
||||
"${@}" || die -n "pytest failed with ${EPYTHON}"
|
||||
return ${?}
|
||||
local ret=${?}
|
||||
|
||||
# remove common temporary directories left over by pytest plugins
|
||||
rm -rf .hypothesis .pytest_cache || die
|
||||
|
||||
return ${ret}
|
||||
}
|
||||
|
||||
# @FUNCTION: eunittest
|
||||
|
||||
Reference in New Issue
Block a user