0

[webtest] rename directory from SmokeTests to TestLists

Bug: 1452264
Change-Id: Ia0ecafc1a5322bd705ffe131aaf2649078f15cfa
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4654766
Commit-Queue: An Sung <ansung@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
Reviewed-by: Ali Juma <ajuma@chromium.org>
Reviewed-by: Weizhong Xia <weizhong@google.com>
Cr-Commit-Position: refs/heads/main@{#1175194}
This commit is contained in:
An Sung
2023-07-26 01:38:43 +00:00
committed by Chromium LUCI CQ
parent 9f2470b35f
commit 65d9eab391
18 changed files with 29 additions and 38 deletions

@ -1226,6 +1226,7 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/tools/",
"//third_party/blink/web_tests/external/wpt/config.json",
"//third_party/blink/web_tests/resources/",
"//third_party/blink/web_tests/TestLists/",
"//third_party/pywebsocket3/src/mod_pywebsocket/",
"//third_party/test_fonts/test_fonts/",
"//third_party/wpt_tools/",
@ -1317,7 +1318,6 @@ if (!is_ios && !is_cronet_build) {
data_deps = [ ":blink_web_tests_support_data" ]
data = [
"//third_party/blink/perf_tests/",
"//third_party/blink/web_tests/SmokeTests/Default.txt",
"//third_party/blink/web_tests/VirtualTestSuites",
# List all test expectations here
@ -1330,7 +1330,6 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/web_tests/TestExpectations",
"//third_party/blink/web_tests/WebDriverExpectations",
"//third_party/blink/web_tests/WebGPUExpectations",
"//third_party/blink/web_tests/SmokeTests/SingleThreadedTests",
# === List Test Cases folders here ===
"//third_party/blink/web_tests/accessibility/",
@ -1436,7 +1435,6 @@ if (!is_ios && !is_cronet_build) {
}
} else if (is_mac) {
data += [
"//third_party/blink/web_tests/SmokeTests/Mac.txt",
"//third_party/blink/web_tests/platform/mac/",
"//third_party/blink/web_tests/platform/mac-mac10.15/",
"//third_party/blink/web_tests/platform/mac-mac11/",
@ -1453,7 +1451,6 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/web_tests/FlagSpecificConfig",
"//third_party/blink/web_tests/FlagExpectations/",
"//third_party/blink/web_tests/flag-specific/",
"//third_party/blink/web_tests/SmokeTests/",
]
}
}
@ -1469,8 +1466,6 @@ if (!is_ios && !is_cronet_build) {
data_deps = [ ":blink_web_tests_support_data" ]
data = [
"//third_party/blink/perf_tests/",
"//third_party/blink/web_tests/SmokeTests/Default.txt",
"//third_party/blink/web_tests/SmokeTests/rel-ready.blink_wpt_tests.filter",
"//third_party/blink/web_tests/VirtualTestSuites",
# List all test expectations here
@ -1483,7 +1478,6 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/web_tests/TestExpectations",
"//third_party/blink/web_tests/WebDriverExpectations",
"//third_party/blink/web_tests/WebGPUExpectations",
"//third_party/blink/web_tests/SmokeTests/SingleThreadedTests",
# === List Test Cases folders here ===
"//third_party/blink/web_tests/external/",
@ -1509,7 +1503,6 @@ if (!is_ios && !is_cronet_build) {
}
} else if (is_mac) {
data += [
"//third_party/blink/web_tests/SmokeTests/Mac.txt",
"//third_party/blink/web_tests/platform/mac/",
"//third_party/blink/web_tests/platform/mac-mac10.15/",
"//third_party/blink/web_tests/platform/mac-mac11-arm64/",
@ -1522,7 +1515,6 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/web_tests/FlagSpecificConfig",
"//third_party/blink/web_tests/FlagExpectations/",
"//third_party/blink/web_tests/flag-specific/",
"//third_party/blink/web_tests/SmokeTests/",
]
}
}
@ -1629,7 +1621,6 @@ if (!is_ios && !is_cronet_build) {
"//third_party/blink/web_tests/TestExpectations",
"//third_party/blink/web_tests/VirtualTestSuites",
"//third_party/blink/web_tests/W3CImportExpectations",
"//third_party/blink/web_tests/SmokeTests/SingleThreadedTests",
"//third_party/blink/web_tests/paint/invalidation/repaint-overlay/",
"//third_party/catapult/common/py_utils/",
"//third_party/catapult/devil/",

@ -11,7 +11,7 @@ Fuchsia layers on top [its own test script] (../../build/fuchsia/test/run_test.p
which handles preparation such as installing the content_shell binary.
Currently, only
[a small subset of web tests](../../third_party/blink/web_tests/SmokeTests/Default.txt)
[a small subset of web tests](../../third_party/blink/web_tests/TestLists/Default.txt)
can be run on Fuchsia. Build the target `blink_web_tests` first before running any
of the commands below:

@ -88,7 +88,7 @@ learn more about TestExpectations and related files.
*** promo
Currently only the tests listed in
[Default.txt](../../third_party/blink/web_tests/SmokeTests/Default.txt) are run
[Default.txt](../../third_party/blink/web_tests/TestLists/Default.txt) are run
on the Fuchsia bots, since running all web tests takes too long on Fuchshia.
Most developers focus their Blink testing on Linux. We rely on the fact that the
Linux and Fuchsia behavior is nearly identical for scenarios outside those
@ -97,7 +97,7 @@ covered by the smoke tests.
*** promo
Similar to Fuchsia's case, the tests listed in [Mac.txt]
(../../third_party/blink/web_tests/SmokeTests/Mac.txt)
(../../third_party/blink/web_tests/TestLists/Mac.txt)
are run on older mac version bots. By doing this we reduced the resources needed to run
the tests. This relies on the fact that the majority of web tests will behavior similarly on
different mac versions.

@ -33,7 +33,7 @@ script_test("chrome_ios_wpt") {
"//third_party/blink/web_tests/resources/testdriver-vendor.js",
"//third_party/blink/web_tests/wptrunner.blink.ini",
"//third_party/blink/web_tests/FlagSpecificConfig",
"//third_party/blink/web_tests/SmokeTests/",
"//third_party/blink/web_tests/TestLists/",
"//.vpython3",
]
data_deps = [

@ -27,7 +27,7 @@ group("wpt_tests_isolate") {
# Configuration files
"//third_party/blink/web_tests/wptrunner.blink.ini",
"//third_party/blink/web_tests/FlagSpecificConfig",
"//third_party/blink/web_tests/SmokeTests/",
"//third_party/blink/web_tests/TestLists/",
# Include the root vpython spec.
"//.vpython3",

@ -397,18 +397,18 @@ def check_virtual_test_suites(host, options):
return failures
def check_smoke_tests(host, options):
def check_test_lists(host, options):
port = host.port_factory.get(options=options)
path = host.filesystem.join(port.web_tests_dir(), 'SmokeTests')
smoke_tests_files = host.filesystem.listdir(path)
path = host.filesystem.join(port.web_tests_dir(), 'TestLists')
test_lists_files = host.filesystem.listdir(path)
failures = []
for smoke_tests_file in smoke_tests_files:
smoke_tests = host.filesystem.read_text_file(
host.filesystem.join(port.web_tests_dir(), 'SmokeTests',
smoke_tests_file))
for test_lists_file in test_lists_files:
test_lists = host.filesystem.read_text_file(
host.filesystem.join(port.web_tests_dir(), 'TestLists',
test_lists_file))
line_number = 0
parsed_lines = {}
for line in smoke_tests.split('\n'):
for line in test_lists.split('\n'):
line_number += 1
line = line.split('#')[0].strip()
if not line:
@ -416,10 +416,10 @@ def check_smoke_tests(host, options):
if line in parsed_lines:
failures.append(
'%s:%d duplicate with line %d: %s' %
(smoke_tests_file, line_number, parsed_lines[line], line))
(test_lists_file, line_number, parsed_lines[line], line))
elif not port.test_exists(line):
failures.append('%s:%d Test does not exist: %s' %
(smoke_tests_file, line_number, line))
(test_lists_file, line_number, line))
parsed_lines[line] = line_number
return failures
@ -433,7 +433,7 @@ def run_checks(host, options):
failures += f
warnings += w
failures.extend(check_virtual_test_suites(host, options))
failures.extend(check_smoke_tests(host, options))
failures.extend(check_test_lists(host, options))
if options.json:
with open(options.json, 'w') as f:

@ -545,14 +545,14 @@ class MainTest(unittest.TestCase):
self.orig_lint_fn = lint_test_expectations.lint
self.orig_check_fn = lint_test_expectations.check_virtual_test_suites
lint_test_expectations.check_virtual_test_suites = lambda host, options: []
self.orig_check_smoke = lint_test_expectations.check_smoke_tests
lint_test_expectations.check_smoke_tests = lambda host, options: []
self.orig_check_test_lists = lint_test_expectations.check_test_lists
lint_test_expectations.check_test_lists = lambda host, options: []
self.stderr = StringIO()
def tearDown(self):
lint_test_expectations.lint = self.orig_lint_fn
lint_test_expectations.check_virtual_test_suites = self.orig_check_fn
lint_test_expectations.check_smoke_tests = self.orig_check_smoke
lint_test_expectations.check_test_lists = self.orig_check_test_lists
def test_success(self):
lint_test_expectations.lint = lambda host, options: ([], [])

@ -1020,7 +1020,7 @@ class Port(object):
# When collecting test cases, skip these directories.
skipped_directories = set([
'platform', 'resources', 'support', 'script-tests', 'reference',
'reftest', 'SmokeTests'
'reftest', 'TestLists'
])
# Also ignore all WPT directories. Note that this is only an
# optimization; is_non_wpt_test_file should skip WPT regardless.
@ -1438,7 +1438,7 @@ class Port(object):
# Historically we only have one smoke tests list. That one now becomes
# the default
return self._filesystem.join(self.web_tests_dir(), 'SmokeTests',
return self._filesystem.join(self.web_tests_dir(), 'TestLists',
'Default.txt')
@memoized
@ -2577,7 +2577,7 @@ class Port(object):
@memoized
def _get_blocked_tests_for_threaded_compositing_testing(self):
path = self._filesystem.join(self.web_tests_dir(),
'SmokeTests/SingleThreadedTests')
'TestLists/SingleThreadedTests')
return set(self._filesystem.read_text_file(path).split('\n'))
def _is_in_allowlist_for_threaded_compositing(self, test_name):

@ -474,7 +474,7 @@ passes/slow.html [ Slow ]
if not filesystem.exists(MOCK_WEB_TESTS + 'SingleThreadedTests'):
filesystem.write_text_file(
MOCK_WEB_TESTS + 'SmokeTests/SingleThreadedTests', """
MOCK_WEB_TESTS + 'TestLists/SingleThreadedTests', """
fast/borders/border-image-outset-split-inline-vertical-lr.html
non/virtual
passes/text.html

@ -200,7 +200,7 @@ class WPTAdapterTest(unittest.TestCase):
def test_flag_specific(self):
self.fs.write_text_file(
self.finder.path_from_web_tests('SmokeTests', 'fake-flag'),
self.finder.path_from_web_tests('TestLists', 'fake-flag'),
textwrap.dedent("""\
# The non-WPT test should be excluded.
external/wpt/dir/
@ -212,7 +212,7 @@ class WPTAdapterTest(unittest.TestCase):
json.dumps([{
'name': 'fake-flag',
'args': ['--enable-features=FakeFeature'],
'smoke_file': 'SmokeTests/fake-flag',
'smoke_file': 'TestLists/fake-flag',
}]))
adapter = WPTAdapter.from_args(self.host,
['--flag-specific=fake-flag'])

@ -42,7 +42,7 @@
{
"name": "highdpi",
"args": ["--force-device-scale-factor=1.5"],
"smoke_file": "SmokeTests/highdpi"
"smoke_file": "TestLists/highdpi"
},
{
"name": "skia-vulkan-swiftshader",
@ -52,7 +52,7 @@
"--use-vulkan=swiftshader",
"--disable-vulkan-fallback-to-gl-for-testing"
],
"smoke_file": "SmokeTests/skia-vulkan-swiftshader"
"smoke_file": "TestLists/skia-vulkan-swiftshader"
},
{
"name": "webgpu",

@ -280,7 +280,7 @@ def _CheckForUnlistedTestFolder(input_api, output_api):
if len(line.split('/')) > 1:
dirs_from_build_gn.append(line.split('/')[-2])
dirs_from_build_gn.extend(
['platform', 'FlagExpectations', 'flag-specific', 'SmokeTests'])
['platform', 'FlagExpectations', 'flag-specific', 'TestLists'])
new_dirs = [x for x in possible_new_dirs if x not in dirs_from_build_gn]
if new_dirs: