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

Unified Diff: test/codegen/expect/language/crash_12118_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/crash_12118_test.js
diff --git a/test/codegen/expect/language/crash_12118_test.js b/test/codegen/expect/language/crash_12118_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..9a71efc4a52b93c5c4a4d6ced015ab670bd59e6a
--- /dev/null
+++ b/test/codegen/expect/language/crash_12118_test.js
@@ -0,0 +1,33 @@
+dart_library.library('language/crash_12118_test', null, /* Imports */[
+ 'dart_sdk'
+], function load__crash_12118_test(exports, dart_sdk) {
+ 'use strict';
+ const core = dart_sdk.core;
+ const dart = dart_sdk.dart;
+ const dartx = dart_sdk.dartx;
+ const crash_12118_test = Object.create(null);
+ let VoidTovoid = () => (VoidTovoid = dart.constFn(dart.definiteFunctionType(dart.void, [])))();
+ crash_12118_test.X = 42;
+ crash_12118_test.A = class A extends core.Object {
+ new(opts) {
+ let x = opts && 'x' in opts ? opts.x : crash_12118_test.X;
+ this.x = x;
+ }
+ };
+ dart.setSignature(crash_12118_test.A, {
+ constructors: () => ({new: dart.definiteFunctionType(crash_12118_test.A, [], {x: dart.dynamic})})
+ });
+ crash_12118_test.B = class B extends crash_12118_test.A {
+ new() {
+ super.new();
+ }
+ };
+ crash_12118_test.main = function() {
+ if (!dart.equals(new crash_12118_test.B().x, 42)) {
+ dart.throw('Test failed');
+ }
+ };
+ dart.fn(crash_12118_test.main, VoidTovoid());
+ // Exports:
+ exports.crash_12118_test = crash_12118_test;
+});
« no previous file with comments | « test/codegen/expect/language/core_type_check_test.js ('k') | test/codegen/expect/language/crash_6725_test_01_multi.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698