diff --git a/test/validations/special/duplicate-whitelist-cleanup.sh b/test/validations/special/duplicate-whitelist-cleanup.sh index 142e1a3432ab..2f0607d8f957 100755 --- a/test/validations/special/duplicate-whitelist-cleanup.sh +++ b/test/validations/special/duplicate-whitelist-cleanup.sh @@ -4,7 +4,7 @@ TMPFILE=`mktemp /tmp/buffer.XXXXXXXX` trap 'rm "$TMPFILE"' EXIT for host in `cat test/validations/special/duplicate-whitelist.txt`; do - REPEATS=`grep -F "target host=\"$host\"" src/chrome/content/rules/*.xml | wc -l` + REPEATS=`egrep -l "" src/chrome/content/rules/*.xml | wc -l` if [ $REPEATS -gt 1 ]; then echo $host fi diff --git a/test/validations/special/duplicate-whitelist.txt b/test/validations/special/duplicate-whitelist.txt index dfd97c354b6a..7491d3644f2a 100644 --- a/test/validations/special/duplicate-whitelist.txt +++ b/test/validations/special/duplicate-whitelist.txt @@ -9,7 +9,6 @@ www1.arun.gov.uk mailing.channel4.com training.citrix.com consumerreports.org -c-spanvideo.org dell.com www.dell.com investors.demandware.com @@ -74,7 +73,6 @@ www2.scribblelive.com sparxtrading.com suppliesfordreams.org www.techrepublic.com -tesco.com thefederalistpapers.org thompsonhotels.com ti.com diff --git a/test/validations/special/run.py b/test/validations/special/run.py index 737fea1001ba..143d6a40c71e 100755 --- a/test/validations/special/run.py +++ b/test/validations/special/run.py @@ -180,24 +180,18 @@ def nomes_all(where=sys.argv[1:]): failure = 1 fail("%s failed test: %s" % (filename, test.__doc__)) - platform_list = xpath_ruleset_platform(tree) - if len(platform_list) == 0: - platform = '' - else: - platform = platform_list[0] - targets = xpath_host(tree) for target in targets: - host_counter.update([(target, platform)]) + host_counter.update([target]) -for (host, platform), count in host_counter.most_common(): +for host, count in host_counter.most_common(): if count > 1: if host in duplicate_allowed_list: - warn("Whitelisted hostname %s with platform '%s' shows up in %d different rulesets." % (host, platform, count)) + warn("Whitelisted hostname %s shows up in %d different rulesets." % (host, count)) else: failure = 1 - fail("Hostname %s with platform '%s' shows up in %d different rulesets." % (host, platform, count)) + fail("Hostname %s shows up in %d different rulesets." % (host, count)) if not is_valid_target_host(host): failure = 1 fail("%s failed: %s" % (host, is_valid_target_host.__doc__))