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

Side by Side Diff: test/codegen/expect/language/async_await_catch_regression_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 unified diff | Download patch
OLDNEW
(Empty)
1 dart_library.library('language/async_await_catch_regression_test', null, /* Impo rts */[
2 'dart_sdk',
3 'expect',
4 'async_helper'
5 ], function load__async_await_catch_regression_test(exports, dart_sdk, expect, a sync_helper) {
6 'use strict';
7 const core = dart_sdk.core;
8 const dart = dart_sdk.dart;
9 const dartx = dart_sdk.dartx;
10 const expect$ = expect.expect;
11 const async_helper$ = async_helper.async_helper;
12 const async_await_catch_regression_test = Object.create(null);
13 let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionT ype(dart.dynamic, [])))();
14 let dynamicTovoid = () => (dynamicTovoid = dart.constFn(dart.definiteFunctionT ype(dart.void, [dart.dynamic])))();
15 async_await_catch_regression_test.foo = function() {
16 return dart.async(function*() {
17 dart.throw(42);
18 }, dart.dynamic);
19 };
20 dart.fn(async_await_catch_regression_test.foo, VoidTodynamic());
21 async_await_catch_regression_test.test = function() {
22 return dart.async(function*() {
23 let exception = null;
24 try {
25 yield async_await_catch_regression_test.foo();
26 } catch (e) {
27 core.print(yield e);
28 yield exception = (yield e);
29 }
30
31 expect$.Expect.equals(42, exception);
32 }, dart.dynamic);
33 };
34 dart.fn(async_await_catch_regression_test.test, VoidTodynamic());
35 async_await_catch_regression_test.main = function() {
36 async_helper$.asyncStart();
37 dart.dsend(async_await_catch_regression_test.test(), 'then', dart.fn(_ => as ync_helper$.asyncEnd(), dynamicTovoid()));
38 };
39 dart.fn(async_await_catch_regression_test.main, VoidTodynamic());
40 // Exports:
41 exports.async_await_catch_regression_test = async_await_catch_regression_test;
42 });
OLDNEW
« no previous file with comments | « test/codegen/expect/language/async_and_or_test.js ('k') | test/codegen/expect/language/async_await_syntax_test_a01a_multi.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698