Browse Source

Add pytest-fail-slow plugin (#43181)

Co-authored-by: getsantry[bot] <66042841+getsantry[bot]@users.noreply.github.com>
Matt Gaunt-Seo @ Sentry.io 2 years ago
parent
commit
f1e1642d46
3 changed files with 3 additions and 1 deletions
  1. 1 1
      .github/actions/setup-sentry/action.yml
  2. 1 0
      requirements-dev-frozen.txt
  3. 1 0
      requirements-dev.txt

+ 1 - 1
.github/actions/setup-sentry/action.yml

@@ -77,7 +77,7 @@ runs:
 
         ### pytest configuration ###
         echo "PY_COLORS=1" >> "$GITHUB_ENV"
-        echo "PYTEST_ADDOPTS=--reruns=5 --durations=10" >> $GITHUB_ENV
+        echo "PYTEST_ADDOPTS=--reruns=5 --durations=10 --fail-slow=60s" >> $GITHUB_ENV
 
         ### pytest-sentry configuration ###
         if [ "$GITHUB_REPOSITORY" = "getsentry/sentry" ]; then

+ 1 - 0
requirements-dev-frozen.txt

@@ -129,6 +129,7 @@ pysocks==1.7.1
 pytest==7.2.0
 pytest-cov==4.0.0
 pytest-django==4.4.0
+pytest-fail-slow==0.3.0
 pytest-rerunfailures==10.2
 pytest-sentry==0.1.11
 pytest-xdist==3.0.2

+ 1 - 0
requirements-dev.txt

@@ -7,6 +7,7 @@ openapi-core>=0.14.2
 pytest>=7.2
 pytest-cov>=4.0.0
 pytest-django>=4.4.0
+pytest-fail-slow>=0.3.0
 pytest-rerunfailures>=10
 pytest-sentry>=0.1.11
 pytest-xdist>=3