Skip to content

Commit 24ca919

Browse files
committed
Account for deleted files in ruleset coverage test.
1 parent d583f55 commit 24ca919

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

test-ruleset-coverage.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,11 @@
66
cd $(dirname $0)
77
TMP=`mktemp`
88
trap 'rm "$TMP"' EXIT
9+
# Git log gives us all changed files. Pipe that through ls to eliminate files
10+
# that have been deleted.
911
if ! git log --name-only --date=local --since=2015-02-05 --pretty=format: \
1012
src/chrome/content/rules/ | sort -u | \
11-
xargs python2.7 https-everywhere-checker/src/https_everywhere_checker/check_rules.py \
13+
xargs ls 2>/dev/null | xargs python2.7 https-everywhere-checker/src/https_everywhere_checker/check_rules.py \
1214
https-everywhere-checker/checker.config.sample ; then
1315
echo "Ruleset test coverage was insufficient. Please add <test url=...> tags " \
1416
"to ruleset with additional HTTP URLs to test rewriting and fetching."

0 commit comments

Comments
 (0)