Migration: add a repro for issue #41409.

Bug: https://github.com/dart-lang/sdk/issues/41409
Change-Id: I1029767745414c472bbe0b6efc7ee1ea6c0ac51e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/146685
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
This commit is contained in:
Paul Berry 2020-05-06 12:59:52 +00:00 committed by commit-bot@chromium.org
parent 7af13443e4
commit 097c3aab2c

View file

@ -1816,6 +1816,23 @@ void main() {
await _checkSingleFileChanges(content, expected);
}
@FailingTest(issue: 'https://github.com/dart-lang/sdk/issues/41409')
Future<void> test_exact_nullability_in_nested_list() async {
var content = '''
f(List<int/*?*/> y) {
var x = <List<int>>[];
x.add(y);
}
''';
var expected = '''
f(List<int?> y) {
var x = <List<int?>>[];
x.add(y);
}
''';
await _checkSingleFileChanges(content, expected);
}
Future<void> test_explicit_nullable_overrides_hard_edge() async {
var content = '''
int f(int/*?*/ i) => i + 1;