| Index: pkg/analyzer/test/generated/static_type_warning_code_test.dart
|
| diff --git a/pkg/analyzer/test/generated/static_type_warning_code_test.dart b/pkg/analyzer/test/generated/static_type_warning_code_test.dart
|
| index fd2950314b00b3009c7045eeac23f91585374667..fa0c16e73e82fb7f82058251a8e587de60ce9058 100644
|
| --- a/pkg/analyzer/test/generated/static_type_warning_code_test.dart
|
| +++ b/pkg/analyzer/test/generated/static_type_warning_code_test.dart
|
| @@ -1189,6 +1189,78 @@ f(T e) { return e.m; }''');
|
| assertErrors(source, [StaticTypeWarningCode.UNDEFINED_GETTER]);
|
| }
|
|
|
| + void test_undefinedSuperGetter() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + get g {
|
| + return super.g;
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_GETTER]);
|
| + }
|
| +
|
| + void test_undefinedSuperOperator_binaryExpression() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + operator +(value) {
|
| + return super + value;
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_OPERATOR]);
|
| + }
|
| +
|
| + void test_undefinedSuperOperator_indexBoth() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + operator [](index) {
|
| + return super[index]++;
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_OPERATOR]);
|
| + }
|
| +
|
| + void test_undefinedSuperOperator_indexSetter() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + operator []=(index, value) {
|
| + return super[index] = 0;
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_OPERATOR]);
|
| + }
|
| +
|
| + void test_undefinedSuperOperator_indexGetter() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + operator [](index) {
|
| + return super[index + 1];
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_OPERATOR]);
|
| + }
|
| +
|
| + void test_undefinedSuperSetter() {
|
| + Source source = addSource(r'''
|
| +class A {}
|
| +class B extends A {
|
| + f() {
|
| + super.m = 0;
|
| + }
|
| +}''');
|
| + resolve(source);
|
| + assertErrors(source, [StaticTypeWarningCode.UNDEFINED_SUPER_SETTER]);
|
| + }
|
| +
|
| void test_undefinedGetter_proxy_annotation_fakeProxy() {
|
| Source source = addSource(r'''
|
| library L;
|
|
|