| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 mock_compiler; | 5 library mock_compiler; |
| 6 | 6 |
| 7 import "package:expect/expect.dart"; | 7 import "package:expect/expect.dart"; |
| 8 import 'dart:collection'; | 8 import 'dart:collection'; |
| 9 import 'dart:uri'; | 9 import 'dart:uri'; |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 class Closure {} | 55 class Closure {} |
| 56 class Null {} | 56 class Null {} |
| 57 class Dynamic_ {} | 57 class Dynamic_ {} |
| 58 class LinkedHashMap {} | 58 class LinkedHashMap {} |
| 59 class ConstantMap {} | 59 class ConstantMap {} |
| 60 class TypeImpl {} | 60 class TypeImpl {} |
| 61 S() {} | 61 S() {} |
| 62 unwrapException(e) {} | 62 unwrapException(e) {} |
| 63 assertHelper(a){} | 63 assertHelper(a){} |
| 64 createRuntimeType(a) {} | 64 createRuntimeType(a) {} |
| 65 createInvocationMirror(a0, a1, a2, a3, a4, a5) {} |
| 65 throwNoSuchMethod(obj, name, arguments, expectedArgumentNames) {} | 66 throwNoSuchMethod(obj, name, arguments, expectedArgumentNames) {} |
| 66 throwAbstractClassInstantiationError(className) {}'''; | 67 throwAbstractClassInstantiationError(className) {}'''; |
| 67 | 68 |
| 68 const String FOREIGN_LIBRARY = r''' | 69 const String FOREIGN_LIBRARY = r''' |
| 69 dynamic JS(String typeDescription, String codeTemplate, | 70 dynamic JS(String typeDescription, String codeTemplate, |
| 70 [var arg0, var arg1, var arg2, var arg3, var arg4, var arg5, var arg6, | 71 [var arg0, var arg1, var arg2, var arg3, var arg4, var arg5, var arg6, |
| 71 var arg7, var arg8, var arg9, var arg10, var arg11]) {}'''; | 72 var arg7, var arg8, var arg9, var arg10, var arg11]) {}'''; |
| 72 | 73 |
| 73 const String DEFAULT_INTERCEPTORSLIB = r''' | 74 const String DEFAULT_INTERCEPTORSLIB = r''' |
| 74 class Interceptor { | 75 class Interceptor { |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 abstract class int extends num { } | 134 abstract class int extends num { } |
| 134 abstract class double extends num { | 135 abstract class double extends num { |
| 135 static var NAN = 0; | 136 static var NAN = 0; |
| 136 static parse(s) {} | 137 static parse(s) {} |
| 137 } | 138 } |
| 138 class bool {} | 139 class bool {} |
| 139 class String implements Pattern {} | 140 class String implements Pattern {} |
| 140 class Object { | 141 class Object { |
| 141 operator ==(other) {} | 142 operator ==(other) {} |
| 142 String toString() { return null; } | 143 String toString() { return null; } |
| 144 noSuchMethod(im) { throw im; } |
| 143 } | 145 } |
| 144 class Type {} | 146 class Type {} |
| 145 class Function {} | 147 class Function {} |
| 146 class List<E> {} | 148 class List<E> {} |
| 147 abstract class Map<K,V> {} | 149 abstract class Map<K,V> {} |
| 148 class DateTime { | 150 class DateTime { |
| 149 DateTime(year); | 151 DateTime(year); |
| 150 DateTime.utc(year); | 152 DateTime.utc(year); |
| 151 } | 153 } |
| 152 abstract class Pattern {} | 154 abstract class Pattern {} |
| (...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 390 } | 392 } |
| 391 } | 393 } |
| 392 | 394 |
| 393 class MockDeferredLoadTask extends DeferredLoadTask { | 395 class MockDeferredLoadTask extends DeferredLoadTask { |
| 394 MockDeferredLoadTask(Compiler compiler) : super(compiler); | 396 MockDeferredLoadTask(Compiler compiler) : super(compiler); |
| 395 | 397 |
| 396 void registerMainApp(LibraryElement mainApp) { | 398 void registerMainApp(LibraryElement mainApp) { |
| 397 // Do nothing. | 399 // Do nothing. |
| 398 } | 400 } |
| 399 } | 401 } |
| OLD | NEW |