From 352acd7771095ae6ac55d29568093c93c2cd11d1 Mon Sep 17 00:00:00 2001 From: Ben Wiederhake Date: Thu, 24 Oct 2024 23:36:54 +0200 Subject: [PATCH] Tests: Prevent executable images or html files during lint --- Meta/lint-executable-resources.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Meta/lint-executable-resources.sh b/Meta/lint-executable-resources.sh index 46d9f1aef71..b65884719ef 100755 --- a/Meta/lint-executable-resources.sh +++ b/Meta/lint-executable-resources.sh @@ -8,8 +8,10 @@ cd "$script_path/.." if [ "$(uname -s)" = "Darwin" ]; then # MacOS's find does not support '-executable' OR '-perm /mode'. BAD_FILES=$(find Base/res/ -type f -perm +111) + BAD_FILES+=$(find Tests/ -name WPT -prune -or -perm +111 \! -type d -print | grep -Ev '\.(sh|py)$' || true) else BAD_FILES=$(find Base/res/ -type f -executable) + BAD_FILES+=$(find Tests/ -name WPT -prune -or -executable \! -type d -print | grep -Ev '\.(sh|py)$' || true) fi if [ -n "${BAD_FILES}" ]