summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--PRESUBMIT.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index e8d8458ec0..a7db1230d4 100644
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -279,11 +279,11 @@ def _CheckTestDuplicates(input_api, output_api):
def _CheckPNGFormat(input_api, output_api):
"""Checks that .png files have a format that will be considered valid by our
test runners. If a file ends with .png, then it must be of the form
- NAME_expected{,mac,win}.pdf.#.png"""
+ NAME_expected(_(win|mac|linux))?.pdf.#.png"""
expected_pattern = input_api.re.compile(
- r'.*_expected(_(mac|win))?\.pdf\..*\.png')
+ r'.+_expected(_(win|mac|linux))?\.pdf\.\d+.png')
results = []
- for f in input_api.AffectedFiles():
+ for f in input_api.AffectedFiles(include_deletes=False):
if not f.LocalPath().endswith('.png'):
continue
if expected_pattern.match(f.LocalPath()):