Skip to content

Commit 7f0de07

Browse files
committed
Added rerun for check-links failures
1 parent 4bf2363 commit 7f0de07

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

test.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,11 @@ check_links()
295295
echo "Checking notebook links"
296296
export JUPYTER_PLATFORM_DIRS=1
297297
jupyter --paths
298-
pytest --check-links docs/Tutorial_*.ipynb notebooks/Tutorial_*.ipynb docs/*.md docs/*.rst ./*.md ./*.rst --check-links-ignore "https://dl.acm.org/doi/10.1145/3357223.3362721"
298+
RERUNS=""
299+
if [[ `pytest --trace-config | grep rerunfailures | wc -l` -gt "0" ]]; then
300+
RERUNS="--reruns 5"
301+
fi
302+
pytest $RERUNS --check-links docs/Tutorial_*.ipynb notebooks/Tutorial_*.ipynb docs/*.md docs/*.rst ./*.md ./*.rst --check-links-ignore "https://dl.acm.org/doi/10.1145/3357223.3362721"
299303
check_errs $?
300304
}
301305

0 commit comments

Comments
 (0)