@@ -19,13 +19,25 @@ RDEPENDS:${PN}-ptest += " \
python3-eventlet \
python3-gevent \
python3-misc \
+ python3-multiprocessing \
python3-pytest \
+ python3-pytest-asyncio \
python3-unittest-automake-output \
"
do_install_ptest() {
install -d ${D}${PTEST_PATH}/tests
cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
+ # tests/docker/* are docker-compose/Dockerfile-driven integration tests
+ # requiring a Docker daemon, which the ptest QEMU environment doesn't have
+ rm -rf ${D}${PTEST_PATH}/tests/docker
+ # upstream's pyproject.toml sets asyncio_mode=auto for the async tests
+ # under tests/dirty and tests/ctl; provide just that bit without pulling
+ # in the rest of upstream's addopts (e.g. --cov=gunicorn)
+ cat > ${D}${PTEST_PATH}/pytest.ini <<EOF
+[pytest]
+asyncio_mode = auto
+EOF
}
RDEPENDS:${PN} += "python3-setuptools python3-fcntl"