From 7bb276d5d5018682db1ac716975220f65cce244a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Besson?= Date: Wed, 24 Jan 2024 08:42:46 +0000 Subject: [PATCH] Remove deprecated usage of pytest-runner - Call pytest directly in app, cli and scripts builds - Remove pytest-runner - Uncap pytest and install pytest-mock by default --- app-build | 2 +- cli-build | 3 ++- requirements.txt | 5 ++--- scripts-build | 3 ++- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/app-build b/app-build index 0374d6fc..680b6c51 100755 --- a/app-build +++ b/app-build @@ -17,4 +17,4 @@ set +u export DJANGO_SETTINGS_MODULE=omeroweb.settings export OMERODIR=/opt/omero/web/OMERO.web export ICE_CONFIG=${OMERO_DIST}/etc/ice.config -python $DIR/setup.py test +pytest -v diff --git a/cli-build b/cli-build index 32bf6772..97e25fbd 100755 --- a/cli-build +++ b/cli-build @@ -14,4 +14,5 @@ PLUGIN=${PLUGIN:-$GUESS} export OMERO_DIST=${OMERO_DIST:-/opt/omero/server/OMERO.server} omero $PLUGIN -h -python setup.py test -t test -i ${OMERO_DIST}/etc/ice.config -vs +export ICE_CONFIG=${OMERO_DIST}/etc/ice.config +pytest -v diff --git a/requirements.txt b/requirements.txt index 908a54ea..685beb48 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,10 +4,9 @@ pep8-naming pre-commit pycodestyle restructuredtext_lint -pytest<5 +pytest attrs restview -mox +pytest-mock # TODO: Apps only pytest-django -pytest-runner diff --git a/scripts-build b/scripts-build index dbcbb578..edc70447 100755 --- a/scripts-build +++ b/scripts-build @@ -8,4 +8,5 @@ set -x cd $TARGET -python setup.py test -t test -i ${OMERO_DIST}/etc/ice.config -v +export ICE_CONFIG=${OMERO_DIST}/etc/ice.config +pytest -v