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

Unified Diff: test/codegen/expect/language/library_private_in_constructor_test.js

Issue 2128353002: Check in codegen test expectations. (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 5 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: test/codegen/expect/language/library_private_in_constructor_test.js
diff --git a/test/codegen/expect/language/library_private_in_constructor_test.js b/test/codegen/expect/language/library_private_in_constructor_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..8571c0c93f09adfc6c5f40cf9b322a7a11e3f838
--- /dev/null
+++ b/test/codegen/expect/language/library_private_in_constructor_test.js
@@ -0,0 +1,61 @@
+dart_library.library('language/library_private_in_constructor_test', null, /* Imports */[
+ 'dart_sdk',
+ 'expect'
+], function load__library_private_in_constructor_test(exports, dart_sdk, expect) {
+ 'use strict';
+ const core = dart_sdk.core;
+ const dart = dart_sdk.dart;
+ const dartx = dart_sdk.dartx;
+ const expect$ = expect.expect;
+ const library_private_in_constructor_test = Object.create(null);
+ const library_private_in_constructor_a = Object.create(null);
+ const library_private_in_constructor_b = Object.create(null);
+ let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [])))();
+ library_private_in_constructor_test.main = function() {
+ let b = new library_private_in_constructor_b.B();
+ expect$.Expect.equals(499, b.x);
+ expect$.Expect.equals(42, b.y);
+ };
+ dart.fn(library_private_in_constructor_test.main, VoidTodynamic());
+ const _val = Symbol('_val');
+ library_private_in_constructor_a.PrivateA = class PrivateA extends core.Object {
+ new() {
+ this[_val] = 499;
+ }
+ };
+ dart.setSignature(library_private_in_constructor_a.PrivateA, {
+ constructors: () => ({new: dart.definiteFunctionType(library_private_in_constructor_a.PrivateA, [])})
+ });
+ library_private_in_constructor_a.fooA = dart.const(new library_private_in_constructor_a.PrivateA());
+ library_private_in_constructor_a.A = class A extends core.Object {
+ new() {
+ this.x = library_private_in_constructor_a.fooA[_val];
+ }
+ };
+ dart.setSignature(library_private_in_constructor_a.A, {
+ constructors: () => ({new: dart.definiteFunctionType(library_private_in_constructor_a.A, [])})
+ });
+ const _val$ = Symbol('_val');
+ library_private_in_constructor_b.PrivateB = class PrivateB extends core.Object {
+ new() {
+ this[_val$] = 42;
+ }
+ };
+ dart.setSignature(library_private_in_constructor_b.PrivateB, {
+ constructors: () => ({new: dart.definiteFunctionType(library_private_in_constructor_b.PrivateB, [])})
+ });
+ library_private_in_constructor_b.fooB = dart.const(new library_private_in_constructor_b.PrivateB());
+ library_private_in_constructor_b.B = class B extends library_private_in_constructor_a.A {
+ new() {
+ this.y = library_private_in_constructor_b.fooB[_val$];
+ super.new();
+ }
+ };
+ dart.setSignature(library_private_in_constructor_b.B, {
+ constructors: () => ({new: dart.definiteFunctionType(library_private_in_constructor_b.B, [])})
+ });
+ // Exports:
+ exports.library_private_in_constructor_test = library_private_in_constructor_test;
+ exports.library_private_in_constructor_a = library_private_in_constructor_a;
+ exports.library_private_in_constructor_b = library_private_in_constructor_b;
+});
« no previous file with comments | « test/codegen/expect/language/library_prefixes_test.js ('k') | test/codegen/expect/language/library_same_name_used_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698