Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(135)

Unified Diff: tests/compiler/dart2js/kernel/impact_test.dart

Issue 2681783005: Support mixin application equivalence in impact_test. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tests/compiler/dart2js/kernel/impact_test.dart
diff --git a/tests/compiler/dart2js/kernel/impact_test.dart b/tests/compiler/dart2js/kernel/impact_test.dart
index 89bee6244a8bfbb10ac8e467fe05023d6ea975fd..5fd2411e036e09f56319ec7d85920b5eb9c3db90 100644
--- a/tests/compiler/dart2js/kernel/impact_test.dart
+++ b/tests/compiler/dart2js/kernel/impact_test.dart
@@ -184,6 +184,8 @@ main() {
testNativeMethodCreates();
testNativeMethodReturns();
testNativeField(null);
+ testMixinInstantiation();
+ testNamedMixinInstantiation();
}
testEmpty() {}
@@ -626,6 +628,8 @@ class NativeClass {
factory NativeClass._() { throw new UnsupportedError("Not supported"); }
}
testNativeField(NativeClass c) => c.field;
+testMixinInstantiation() => new Sub();
+testNamedMixinInstantiation() => new NamedMixin();
''',
'sdk/tests/compiler/dart2js_native/helper.dart': '''
import 'dart:_js_helper';
@@ -644,6 +648,12 @@ class GenericClass<X, Y> {
typedef Typedef();
typedef X GenericTypedef<X, Y>(Y y);
+class Super {}
+class Mixin1 {}
+class Mixin2 {}
+class Sub extends Super with Mixin1, Mixin2 {}
+class NamedMixin = Super with Mixin1, Mixin2;
+
const String _serializedScriptValue =
'num|String|bool|'
'JSExtendableArray|=Object';
« no previous file with comments | « pkg/compiler/lib/src/kernel/world_builder.dart ('k') | tests/compiler/dart2js/serialization/test_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698