diff --git a/packages/flutter_tools/test/commands.shard/permeable/create_test.dart b/packages/flutter_tools/test/commands.shard/permeable/create_test.dart index 8d9707c4e1..c2de75abcc 100644 --- a/packages/flutter_tools/test/commands.shard/permeable/create_test.dart +++ b/packages/flutter_tools/test/commands.shard/permeable/create_test.dart @@ -3120,11 +3120,16 @@ Future _analyzeProject(String workingDir, { List expectedFailures } expect(exec.exitCode, isNot(0)); String lineParser(String line) { - final String analyzerSeparator = globals.platform.isWindows ? ' - ' : ' • '; - final List lineComponents = line.trim().split(analyzerSeparator); - final String lintName = lineComponents.removeLast(); - final String location = lineComponents.removeLast(); - return '$location: $lintName'; + try { + final String analyzerSeparator = globals.platform.isWindows ? ' - ' : ' • '; + final List lineComponents = line.trim().split(analyzerSeparator); + final String lintName = lineComponents.removeLast(); + final String location = lineComponents.removeLast(); + return '$location: $lintName'; + // Add debugging for https://github.com/flutter/flutter/issues/111272 + } on RangeError catch (err) { + fail('Received "$err" while trying to parse:\n\n$line'); + } } final List errors = const LineSplitter().convert(exec.stdout.toString()) .where((String line) {