Skip to content

Commit 0baf81e

Browse files
scheglovcommit-bot@chromium.org
authored andcommitted
Tests for Never and potential nullable / non-nullable.
[email protected], [email protected] Change-Id: Iad0f455f67a9593ebca20b97a91369fc59023c87 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/107701 Reviewed-by: Brian Wilkerson <[email protected]> Commit-Queue: Konstantin Shcheglov <[email protected]>
1 parent 26d308a commit 0baf81e

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

‎pkg/analyzer/test/generated/type_system_test.dart‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3203,6 +3203,10 @@ class TypeSystemTest extends AbstractTypeSystemTest {
32033203
);
32043204
}
32053205

3206+
test_isPotentiallyNonNullable_never() {
3207+
expect(typeSystem.isPotentiallyNonNullable(neverType), true);
3208+
}
3209+
32063210
test_isPotentiallyNonNullable_none() {
32073211
expect(typeSystem.isPotentiallyNonNullable(noneType), true);
32083212
}
@@ -3254,6 +3258,10 @@ class TypeSystemTest extends AbstractTypeSystemTest {
32543258
);
32553259
}
32563260

3261+
test_isPotentiallyNullable_never() {
3262+
expect(typeSystem.isPotentiallyNullable(neverType), false);
3263+
}
3264+
32573265
test_isPotentiallyNullable_none() {
32583266
expect(typeSystem.isPotentiallyNullable(noneType), false);
32593267
}

0 commit comments

Comments
 (0)