Skip to content

Commit 6d2b334

Browse files
committed
Ignore the links generated by JavaScript
Wget doesn't run the javascript but follows the link used as template.
1 parent d7cd81f commit 6d2b334

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/jobs/webstandard.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,16 @@ if [ "$ROLE" = "public" ]; then
8888
# It's expected to encounter a 401 for the login page as we supply the wrong password
8989
EXPECTED_HTTP_CODES="$EXPECTED_HTTP_CODES\|401"
9090
fi
91+
92+
HTTP_404_IGNORED="robots.txt\|imgBase.replace"
93+
9194
set +e
92-
NUM_ERRORS=$(grep -v "HTTP/1.1\" \($EXPECTED_HTTP_CODES\)" /var/log/nginx/domjudge.log | grep -v "robots.txt" -c; if [ "$?" -gt 1 ]; then exit 127; fi)
95+
NUM_ERRORS=$(grep -v "HTTP/1.1\" \($EXPECTED_HTTP_CODES\)" /var/log/nginx/domjudge.log | grep -v "${HTTP_404_IGNORED}" -c; if [ "$?" -gt 1 ]; then exit 127; fi)
9396
set -e
9497
echo "$NUM_ERRORS"
9598
9699
if [ "$NUM_ERRORS" -ne 0 ]; then
97-
grep -v "HTTP/1.1\" \($EXPECTED_HTTP_CODES\)" /var/log/nginx/domjudge.log | grep -v "robots.txt"
100+
grep -v "HTTP/1.1\" \($EXPECTED_HTTP_CODES\)" /var/log/nginx/domjudge.log | grep -v "${HTTP_404_IGNORED}"
98101
exit 1
99102
fi
100103
section_end

0 commit comments

Comments
 (0)