| Index: tools/telemetry/telemetry/page/test_expectations.py
|
| diff --git a/tools/telemetry/telemetry/page/test_expectations.py b/tools/telemetry/telemetry/page/test_expectations.py
|
| index 2c2f2c679c51b4269492535a8df13e6c6e46892b..df2e68632d074d0a538388b25ea4f993c3c5ed66 100644
|
| --- a/tools/telemetry/telemetry/page/test_expectations.py
|
| +++ b/tools/telemetry/telemetry/page/test_expectations.py
|
| @@ -12,9 +12,10 @@ GPU_MODIFIERS = ['amd', 'arm', 'broadcom', 'hisilicon', 'intel', 'imagination',
|
| CONFIG_MODIFIERS = ['debug', 'release']
|
|
|
| class Expectation(object):
|
| - def __init__(self, expectation, url_pattern, conditions=None, bug=None):
|
| + def __init__(self, expectation, pattern, conditions=None, bug=None):
|
| self.expectation = expectation.lower()
|
| - self.url_pattern = url_pattern
|
| + self.name_pattern = pattern
|
| + self.url_pattern = pattern
|
| self.bug = bug
|
|
|
| self.os_conditions = []
|
| @@ -71,7 +72,9 @@ class TestExpectations(object):
|
| gpu_info = None
|
|
|
| for e in self.expectations:
|
| - if fnmatch.fnmatch(page.url, e.url_pattern):
|
| + matches_url = fnmatch.fnmatch(page.url, e.url_pattern)
|
| + matches_name = page.name and fnmatch.fnmatch(page.name, e.name_pattern)
|
| + if matches_url or matches_name:
|
| if gpu_info == None and browser.supports_system_info:
|
| gpu_info = browser.GetSystemInfo().gpu
|
| if self._ModifiersApply(platform, gpu_info, e):
|
|
|