mirror of
https://github.com/flutter/packages.git
synced 2025-08-24 03:18:54 +08:00
[tool] Add initial file-based command skipping (#8928)
Adds initial file-based filtering. This does not attempt to be comprehensive, just to get some low-hanging fruit, and to create a blueprint for anyone to follow in the future when adding more filtering. I expect that once this is in place, what will happen is that as we notice cases where PRs are hitting slow or flaky tests that they clearly don't need to, we can incrementally improve the filtering on demand. Fixes https://github.com/flutter/flutter/issues/136394
This commit is contained in:
@ -9,6 +9,7 @@ import 'dart:io';
|
||||
import 'package:file/file.dart';
|
||||
|
||||
import 'common/core.dart';
|
||||
import 'common/file_filters.dart';
|
||||
import 'common/output_utils.dart';
|
||||
import 'common/package_looping_command.dart';
|
||||
import 'common/plugin_utils.dart';
|
||||
@ -68,6 +69,11 @@ class DriveExamplesCommand extends PackageLoopingCommand {
|
||||
|
||||
Map<String, List<String>> _targetDeviceFlags = const <String, List<String>>{};
|
||||
|
||||
@override
|
||||
bool shouldIgnoreFile(String path) {
|
||||
return isRepoLevelNonCodeImpactingFile(path) || isPackageSupportFile(path);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<void> initializeRun() async {
|
||||
final List<String> platformSwitches = <String>[
|
||||
|
Reference in New Issue
Block a user