Skip to content

Commit 19875ee

Browse files
OrKoNDevtools-frontend LUCI CQ
authored andcommitted
Cleanup: remove interaction test left-overs
Goldens are moved to `test/goldens`. Fixed: 404156431 Change-Id: I351e738740d548b5c4f55f75a0f561e382b5c947 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6680473 Reviewed-by: Jack Franklin <jacktfranklin@chromium.org> Reviewed-by: Nikolay Vitkov <nvitkov@chromium.org> Commit-Queue: Alex Rudenko <alexrudenko@chromium.org>
1 parent 6f40ae5 commit 19875ee

File tree

93 files changed

+9
-738
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+9
-738
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
/scripts/visualize_deps/out
2222
config.gypi
2323
/karma-coverage
24-
/interactions-coverage
2524
/perf-data
2625
npm-debug.log
2726
/scripts/protocol_typescript/*.js

.stylelintignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
front_end/third_party
22
karma-coverage
3-
interactions-coverage
43
node_modules
54
out
65
test/**/fixtures

PRESUBMIT.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -436,15 +436,6 @@ def CheckForTooLargeFiles(input_api, output_api):
436436

437437

438438
def CheckObsoleteScreenshotGoldens(input_api, output_api):
439-
interaction_test_root_path = input_api.os_path.join(
440-
input_api.PresubmitLocalPath(), 'test', 'interactions')
441-
interaction_test_files = [interaction_test_root_path]
442-
443-
interaction_test_files_changed = _GetAffectedFiles(input_api,
444-
interaction_test_files,
445-
[], [])
446-
if len(interaction_test_files_changed) == 0:
447-
return []
448439
script_path = input_api.os_path.join(input_api.PresubmitLocalPath(),
449440
'scripts', 'test',
450441
'check_obsolete_goldens.js')

eslint.config.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -698,7 +698,6 @@ export default defineConfig([
698698
'rulesdir/no-assert-equal-boolean-null-undefined': 'error',
699699
'rulesdir/no-imperative-dom-api': 'off',
700700
'rulesdir/no-lit-render-outside-of-view': 'off',
701-
'rulesdir/no-screenshot-test-outside-perf-panel': 'error',
702701
'rulesdir/prefer-assert-instance-of': 'error',
703702
'rulesdir/prefer-assert-is-ok': 'error',
704703
'rulesdir/prefer-assert-length-of': 'error',

front_end/panels/ai_assistance/BUILD.gn

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ devtools_entrypoint("bundle") {
6262

6363
visibility = [
6464
":*",
65-
"../../../test/interactions/*",
6665
"../../entrypoints/*",
6766
"../../ui/components/docs/ai_assistance/*",
6867
"../explain",

front_end/panels/explain/BUILD.gn

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ devtools_entrypoint("bundle") {
4747

4848
visibility = [
4949
":*",
50-
"../../../test/interactions/*",
5150
"../../entrypoints/*",
5251
"../../legacy_test_runner/*",
5352
"../../ui/components/docs/console_insight/*",

front_end/panels/recorder/models/BUILD.gn

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ devtools_entrypoint("bundle") {
5050
":*",
5151
"../*",
5252
"../../../../test/e2e/recorder/*",
53-
"../../../../test/interactions/panels/recorder/*",
5453
"../../../ui/components/docs/*",
5554
"../../../ui/components/docs/recorder_injected/*",
5655
"../../entrypoints/main/*",

scripts/eslint_rules/lib/no-screenshot-test-outside-perf-panel.ts

Lines changed: 0 additions & 77 deletions
This file was deleted.

scripts/eslint_rules/tests/no-screenshot-test-outside-perf-panel.test.ts

Lines changed: 0 additions & 99 deletions
This file was deleted.

scripts/test/check_obsolete_goldens.js

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,8 @@ const yargsObject = yargs(hideBin(process.argv))
2121

2222
const shouldRemoveFiles = yargsObject.removeFiles === true;
2323
const SOURCE_ROOT = path.resolve(__dirname, path.join('..', '..'));
24-
const interactionTestRoot = path.join(SOURCE_ROOT, 'test', 'interactions');
25-
2624
const unitTestRoot = path.join(SOURCE_ROOT, 'front_end');
27-
// TODO: update the goldens location once interaction tests are
28-
// migrated.
29-
const GOLDENS_LOCATION = path.join(interactionTestRoot, 'goldens');
30-
31-
const interactionTestFiles =
32-
glob.sync('**/*_test.ts', {cwd: interactionTestRoot}).map(file => path.join(interactionTestRoot, file));
25+
const GOLDENS_LOCATION = path.join(SOURCE_ROOT, 'test', 'goldens');
3326
const unitTestFiles = glob.sync('**/*.test.ts', {cwd: unitTestRoot}).map(file => path.join(unitTestRoot, file));
3427

3528
function findScreenshotsToCheck(folder) {
@@ -65,10 +58,9 @@ function checkGoldensForPlatform(platform) {
6558

6659
for (const golden of goldens) {
6760
const relativeGoldenPath = path.relative(platformRoot, golden).replace(/\\/g, '/');
68-
const interactions = checkFolder(relativeGoldenPath, interactionTestFiles);
6961
const units = checkFolder(relativeGoldenPath, unitTestFiles);
7062

71-
if (!interactions && !units) {
63+
if (!units) {
7264
obsoleteImages.push(path.join(platform, relativeGoldenPath));
7365
}
7466
}

0 commit comments

Comments
 (0)