Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library test.search.element_references; | 5 library test.search.element_references; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:analysis_server/plugin/protocol/protocol.dart'; | 9 import 'package:analysis_server/plugin/protocol/protocol.dart'; |
| 10 import 'package:analysis_server/src/services/index/index.dart'; | 10 import 'package:analysis_server/src/services/index/index.dart'; |
| (...skipping 721 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 732 { | 732 { |
| 733 assertHasResult(SearchResultKind.INVOCATION, 'test(1);'); | 733 assertHasResult(SearchResultKind.INVOCATION, 'test(1);'); |
| 734 expect(result.isPotential, isFalse); | 734 expect(result.isPotential, isFalse); |
| 735 } | 735 } |
| 736 { | 736 { |
| 737 assertHasResult(SearchResultKind.INVOCATION, 'test(2);'); | 737 assertHasResult(SearchResultKind.INVOCATION, 'test(2);'); |
| 738 expect(result.isPotential, isTrue); | 738 expect(result.isPotential, isTrue); |
| 739 } | 739 } |
| 740 } | 740 } |
| 741 | 741 |
| 742 test_potential_method_definedInSubclass() async { | 742 fail_potential_method_definedInSubclass() async { |
|
Brian Wilkerson
2016/03/11 21:50:16
Should we create an issue to track this?
| |
| 743 addTestFile(''' | 743 addTestFile(''' |
| 744 class Base { | 744 class Base { |
| 745 methodInBase() { | 745 methodInBase() { |
| 746 test(1); | 746 test(1); |
| 747 } | 747 } |
| 748 } | 748 } |
| 749 class Derived extends Base { | 749 class Derived extends Base { |
| 750 test(_) {} // of Derived | 750 test(_) {} // of Derived |
| 751 methodInDerived() { | 751 methodInDerived() { |
| 752 test(2); | 752 test(2); |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 878 print(vvv); | 878 print(vvv); |
| 879 } | 879 } |
| 880 '''); | 880 '''); |
| 881 Request request = new SearchFindElementReferencesParams(testFile, 0, false) | 881 Request request = new SearchFindElementReferencesParams(testFile, 0, false) |
| 882 .toRequest('0'); | 882 .toRequest('0'); |
| 883 Response response = await waitResponse(request); | 883 Response response = await waitResponse(request); |
| 884 expect(response.error, isNotNull); | 884 expect(response.error, isNotNull); |
| 885 expect(response.error.code, RequestErrorCode.NO_INDEX_GENERATED); | 885 expect(response.error.code, RequestErrorCode.NO_INDEX_GENERATED); |
| 886 } | 886 } |
| 887 } | 887 } |
| OLD | NEW |