| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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.src.serialization.elements_test; | 5 library test.src.serialization.elements_test; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:analyzer/dart/ast/ast.dart'; | 9 import 'package:analyzer/dart/ast/ast.dart'; |
| 10 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; | 10 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; |
| (...skipping 9417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9428 '''); | 9428 '''); |
| 9429 } | 9429 } |
| 9430 | 9430 |
| 9431 test_typedef_parameters() async { | 9431 test_typedef_parameters() async { |
| 9432 var library = await checkLibrary('typedef F(x, y);'); | 9432 var library = await checkLibrary('typedef F(x, y);'); |
| 9433 checkElementText(library, r''' | 9433 checkElementText(library, r''' |
| 9434 typedef dynamic F(dynamic x, dynamic y); | 9434 typedef dynamic F(dynamic x, dynamic y); |
| 9435 '''); | 9435 '''); |
| 9436 } | 9436 } |
| 9437 | 9437 |
| 9438 test_typedef_parameters_named() async { |
| 9439 var library = await checkLibrary('typedef F({y, z, x});'); |
| 9440 checkElementText(library, r''' |
| 9441 typedef dynamic F({dynamic y}, {dynamic z}, {dynamic x}); |
| 9442 '''); |
| 9443 } |
| 9444 |
| 9438 test_typedef_return_type() async { | 9445 test_typedef_return_type() async { |
| 9439 var library = await checkLibrary('typedef int F();'); | 9446 var library = await checkLibrary('typedef int F();'); |
| 9440 checkElementText(library, r''' | 9447 checkElementText(library, r''' |
| 9441 typedef int F(); | 9448 typedef int F(); |
| 9442 '''); | 9449 '''); |
| 9443 } | 9450 } |
| 9444 | 9451 |
| 9445 test_typedef_return_type_generic() async { | 9452 test_typedef_return_type_generic() async { |
| 9446 var library = await checkLibrary('typedef T F<T>();'); | 9453 var library = await checkLibrary('typedef T F<T>();'); |
| 9447 checkElementText(library, r''' | 9454 checkElementText(library, r''' |
| (...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 10057 fail('Unexpectedly tried to get unlinked summary for $uri'); | 10064 fail('Unexpectedly tried to get unlinked summary for $uri'); |
| 10058 } | 10065 } |
| 10059 return serializedUnit; | 10066 return serializedUnit; |
| 10060 } | 10067 } |
| 10061 | 10068 |
| 10062 @override | 10069 @override |
| 10063 bool hasLibrarySummary(String uri) { | 10070 bool hasLibrarySummary(String uri) { |
| 10064 return true; | 10071 return true; |
| 10065 } | 10072 } |
| 10066 } | 10073 } |
| OLD | NEW |