Skip to content

Commit

Permalink
Fetch the full history of master before diff-ing it against HEAD
Browse files Browse the repository at this point in the history
The `Run tests` jobs were broken with 1ae4126
The problem is that the project uses `fetch-depth: 1` (the default) and
thus has no branch history.
Using `fetch-depth: 0` would fetch the whole history for **all**
branches and tags, which would be unnecessary.

Refs:
- actions/checkout#296
- actions/checkout#301

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
(cherry picked from commit e3c24c6)
  • Loading branch information
martin-g committed Oct 13, 2023
1 parent e8e60a3 commit 901959f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/GithubActionTests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ jobs:
run: |
eval "$(conda shell.bash hook)"
conda activate bioconda
git fetch origin master:refs/remotes/origin/master
if git diff --name-only origin/master...HEAD | grep -vE ^docs; then
py.test --durations=0 test/ -v --log-level=DEBUG --tb=native -m '${{ matrix.py_test_marker }}'
else
Expand Down Expand Up @@ -70,6 +71,7 @@ jobs:
run: |
eval "$(conda shell.bash hook)"
conda activate bioconda
git fetch origin master:refs/remotes/origin/master
if git diff --name-only origin/master...HEAD | grep -vE ^docs; then
py.test --durations=0 test/ -v --log-level=DEBUG -k "not docker" --tb=native
else
Expand Down

0 comments on commit 901959f

Please sign in to comment.