Silence new analyzer warnings (#6866)
See https://github.com/flutter/flutter/pull/6861 This silences all but two of the warnings from https://travis-ci.org/flutter/flutter/builds/176055550 One of the silenced warnings was a genuine code error. Some of the others were correct but there was no way for the analyzer to know, and I worked around them. The remainder are problems with the analyzer, specifically https://github.com/dart-lang/sdk/issues/27827 and https://github.com/dart-lang/sdk/issues/27504.
This commit is contained in:
@@ -342,7 +342,7 @@ abstract class TestWidgetsFlutterBinding extends BindingBase
|
||||
stack: stack,
|
||||
context: 'running a test',
|
||||
library: 'Flutter test framework',
|
||||
stackFilter: (List<String> frames) {
|
||||
stackFilter: (Iterable<String> frames) {
|
||||
return FlutterError.defaultStackFilter(frames.skip(stackLinesToOmit));
|
||||
},
|
||||
informationCollector: (StringBuffer information) {
|
||||
|
||||
@@ -130,7 +130,7 @@ class WidgetController {
|
||||
TestAsyncUtils.guardSync();
|
||||
return allElements
|
||||
.where((Element element) => element is StatefulElement)
|
||||
.map((StatefulElement element) => element.state);
|
||||
.map((StatefulElement element) => element.state); // ignore: INVALID_CAST_FUNCTION_EXPR, https://github.com/dart-lang/sdk/issues/27827
|
||||
}
|
||||
|
||||
/// The matching state in the widget tree.
|
||||
|
||||
Reference in New Issue
Block a user