diff --git a/script/tool/CHANGELOG.md b/script/tool/CHANGELOG.md index fbf7610b3e..8f2807f0dd 100644 --- a/script/tool/CHANGELOG.md +++ b/script/tool/CHANGELOG.md @@ -1,4 +1,4 @@ -## NEXT +## 0.8.0 - Ensures that `firebase-test-lab` runs include an `integration_test` runner. - Adds a `make-deps-path-based` command to convert inter-repo package @@ -18,6 +18,7 @@ - Adds support for `CHROME_EXECUTABLE` in `drive-examples` to match similar `flutter` behavior. - Validates `default_package` entries in plugins. +- Removes `allow-warnings` from the `podspecs` command. ## 0.7.3 diff --git a/script/tool/lib/src/lint_podspecs_command.dart b/script/tool/lib/src/lint_podspecs_command.dart index ee44a82da5..198dd94721 100644 --- a/script/tool/lib/src/lint_podspecs_command.dart +++ b/script/tool/lib/src/lint_podspecs_command.dart @@ -26,13 +26,7 @@ class LintPodspecsCommand extends PackageLoopingCommand { Directory packagesDir, { ProcessRunner processRunner = const ProcessRunner(), Platform platform = const LocalPlatform(), - }) : super(packagesDir, processRunner: processRunner, platform: platform) { - argParser.addMultiOption('ignore-warnings', - help: - 'Do not pass --allow-warnings flag to "pod lib lint" for podspecs ' - 'with this basename (example: plugins with known warnings)', - valueHelp: 'podspec_file_name'); - } + }) : super(packagesDir, processRunner: processRunner, platform: platform); @override final String name = 'podspecs'; @@ -118,8 +112,6 @@ class LintPodspecsCommand extends PackageLoopingCommand { Future _runPodLint(String podspecPath, {required bool libraryLint}) async { - final bool allowWarnings = (getStringListArg('ignore-warnings')) - .contains(p.basenameWithoutExtension(podspecPath)); final List arguments = [ 'lib', 'lint', @@ -127,7 +119,6 @@ class LintPodspecsCommand extends PackageLoopingCommand { '--configuration=Debug', // Release targets unsupported arm64 simulators. Use Debug to only build against targeted x86_64 simulator devices. '--skip-tests', '--use-modular-headers', // Flutter sets use_modular_headers! in its templates. - if (allowWarnings) '--allow-warnings', if (libraryLint) '--use-libraries' ]; diff --git a/script/tool/pubspec.yaml b/script/tool/pubspec.yaml index 4849feee7b..9ca5e2b775 100644 --- a/script/tool/pubspec.yaml +++ b/script/tool/pubspec.yaml @@ -1,7 +1,7 @@ name: flutter_plugin_tools description: Productivity utils for flutter/plugins and flutter/packages repository: https://github.com/flutter/plugins/tree/main/script/tool -version: 0.7.2 +version: 0.8.0 dependencies: args: ^2.1.0 @@ -26,7 +26,6 @@ dev_dependencies: build_runner: ^2.0.3 matcher: ^0.12.10 mockito: ^5.0.7 - pedantic: ^1.11.0 environment: sdk: '>=2.12.0 <3.0.0' diff --git a/script/tool/test/lint_podspecs_command_test.dart b/script/tool/test/lint_podspecs_command_test.dart index 4424727402..bccbec6786 100644 --- a/script/tool/test/lint_podspecs_command_test.dart +++ b/script/tool/test/lint_podspecs_command_test.dart @@ -123,48 +123,6 @@ void main() { expect(output, contains('Bar')); }); - test('allow warnings for podspecs with known warnings', () async { - final Directory plugin1Dir = createFakePlugin('plugin1', packagesDir, - extraFiles: ['plugin1.podspec']); - - final List output = await runCapturingPrint( - runner, ['podspecs', '--ignore-warnings=plugin1']); - - expect( - processRunner.recordedCalls, - orderedEquals([ - ProcessCall('which', const ['pod'], packagesDir.path), - ProcessCall( - 'pod', - [ - 'lib', - 'lint', - plugin1Dir.childFile('plugin1.podspec').path, - '--configuration=Debug', - '--skip-tests', - '--use-modular-headers', - '--allow-warnings', - '--use-libraries' - ], - packagesDir.path), - ProcessCall( - 'pod', - [ - 'lib', - 'lint', - plugin1Dir.childFile('plugin1.podspec').path, - '--configuration=Debug', - '--skip-tests', - '--use-modular-headers', - '--allow-warnings', - ], - packagesDir.path), - ]), - ); - - expect(output, contains('Linting plugin1.podspec')); - }); - test('fails if pod is missing', () async { createFakePlugin('plugin1', packagesDir, extraFiles: ['plugin1.podspec']);