Skip to content

Commit

Permalink
Updated tests for GH actions
Browse files Browse the repository at this point in the history
  • Loading branch information
RhetTbull committed Jun 30, 2024
1 parent 7cd2a49 commit 2739d12
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10"]
python-version: ["3.10", "3.11", "3.12"]

env:
GITHUB_ACTION: 1
Expand Down
9 changes: 5 additions & 4 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@

# how long to wait for metadata to be written to disk
# if running in GitHub Actions, wait longer
SNOOZE_TIME = 0.5 if os.environ.get("GITHUB_ACTION") else 0.1
# Finder comments need more time to be written to disk
FINDER_COMMENT_SNOOZE = 2.0
GH_ACTION_SNOOZE = 10.0
SNOOZE_TIME = GH_ACTION_SNOOZE if os.environ.get("GITHUB_ACTION") else 0.1
# some tests need a longer snooze time
LONG_SNOOZE = 10.0 if os.environ.get("GITHUB_ACTION") else 3.0
LONG_SNOOZE = GH_ACTION_SNOOZE if os.environ.get("GITHUB_ACTION") else 3.0
# Finder comments need more time to be written to disk
FINDER_COMMENT_SNOOZE = LONG_SNOOZE

def snooze(seconds: float = SNOOZE_TIME) -> None:
"""Sleep for a bit to allow Finder to update metadata"""
Expand Down

0 comments on commit 2739d12

Please sign in to comment.