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

Unified Diff: test/codegen/expect/language/static_postfix_operator_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/static_postfix_operator_test.js
diff --git a/test/codegen/expect/language/static_postfix_operator_test.js b/test/codegen/expect/language/static_postfix_operator_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..b3466a27cba9a0855b147a2699e28ba872d2596f
--- /dev/null
+++ b/test/codegen/expect/language/static_postfix_operator_test.js
@@ -0,0 +1,48 @@
+dart_library.library('language/static_postfix_operator_test', null, /* Imports */[
+ 'dart_sdk',
+ 'expect'
+], function load__static_postfix_operator_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 static_postfix_operator_test = Object.create(null);
+ let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [])))();
+ static_postfix_operator_test.a = 0;
+ static_postfix_operator_test.b = 0;
+ static_postfix_operator_test.withTryFinally = function() {
+ let inIt = false;
+ try {
+ if ((() => {
+ let x = static_postfix_operator_test.a;
+ static_postfix_operator_test.a = dart.notNull(x) + 1;
+ return x;
+ })() == 0) {
+ inIt = true;
+ }
+ } finally {
+ }
+ expect$.Expect.isTrue(inIt);
+ };
+ dart.fn(static_postfix_operator_test.withTryFinally, VoidTodynamic());
+ static_postfix_operator_test.withoutTryFinally = function() {
+ let inIt = false;
+ if ((() => {
+ let x = static_postfix_operator_test.b;
+ static_postfix_operator_test.b = dart.notNull(x) + 1;
+ return x;
+ })() == 0) {
+ inIt = true;
+ }
+ expect$.Expect.isTrue(inIt);
+ };
+ dart.fn(static_postfix_operator_test.withoutTryFinally, VoidTodynamic());
+ static_postfix_operator_test.main = function() {
+ static_postfix_operator_test.withTryFinally();
+ static_postfix_operator_test.withoutTryFinally();
+ };
+ dart.fn(static_postfix_operator_test.main, VoidTodynamic());
+ // Exports:
+ exports.static_postfix_operator_test = static_postfix_operator_test;
+});

Powered by Google App Engine
This is Rietveld 408576698