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

Unified Diff: test/codegen/expect/language/resolve_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
« no previous file with comments | « test/codegen/expect/language/resolution_test.js ('k') | test/codegen/expect/language/rethrow_test.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/codegen/expect/language/resolve_test.js
diff --git a/test/codegen/expect/language/resolve_test.js b/test/codegen/expect/language/resolve_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..f24f05d49ffb1c1c992c4552cb1a735ed9dc291c
--- /dev/null
+++ b/test/codegen/expect/language/resolve_test.js
@@ -0,0 +1,52 @@
+dart_library.library('language/resolve_test', null, /* Imports */[
+ 'dart_sdk',
+ 'expect'
+], function load__resolve_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 resolve_test = Object.create(null);
+ let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [])))();
+ resolve_test.A = class A extends core.Object {
+ static staticCall() {
+ return 4;
+ }
+ dynamicCall() {
+ return 5;
+ }
+ ovrDynamicCall() {
+ return 6;
+ }
+ };
+ dart.setSignature(resolve_test.A, {
+ methods: () => ({
+ dynamicCall: dart.definiteFunctionType(dart.dynamic, []),
+ ovrDynamicCall: dart.definiteFunctionType(dart.dynamic, [])
+ }),
+ statics: () => ({staticCall: dart.definiteFunctionType(dart.dynamic, [])}),
+ names: ['staticCall']
+ });
+ resolve_test.B = class B extends resolve_test.A {
+ ovrDynamicCall() {
+ return -6;
+ }
+ };
+ resolve_test.ResolveTest = class ResolveTest extends core.Object {
+ static testMain() {
+ let b = new resolve_test.B();
+ expect$.Expect.equals(3, dart.dsend(dart.dsend(b.dynamicCall(), '+', resolve_test.A.staticCall()), '+', b.ovrDynamicCall()));
+ }
+ };
+ dart.setSignature(resolve_test.ResolveTest, {
+ statics: () => ({testMain: dart.definiteFunctionType(dart.dynamic, [])}),
+ names: ['testMain']
+ });
+ resolve_test.main = function() {
+ resolve_test.ResolveTest.testMain();
+ };
+ dart.fn(resolve_test.main, VoidTodynamic());
+ // Exports:
+ exports.resolve_test = resolve_test;
+});
« no previous file with comments | « test/codegen/expect/language/resolution_test.js ('k') | test/codegen/expect/language/rethrow_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698