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

Unified Diff: tests/compiler/dart2js/js_backend_cps_ir_control_flow.dart

Issue 810183003: Split js_backend_cps_ir tests into multiple test units. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 11 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: tests/compiler/dart2js/js_backend_cps_ir_control_flow.dart
diff --git a/tests/compiler/dart2js/js_backend_cps_ir_control_flow.dart b/tests/compiler/dart2js/js_backend_cps_ir_control_flow.dart
deleted file mode 100644
index 2695588a82560ce4dafae22a62b64594f1e16dc3..0000000000000000000000000000000000000000
--- a/tests/compiler/dart2js/js_backend_cps_ir_control_flow.dart
+++ /dev/null
@@ -1,140 +0,0 @@
-// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-// Tests of control flow statements.
-
-library control_flow_tests;
-
-import 'js_backend_cps_ir_test.dart';
-
-const List<TestEntry> tests = const [
- const TestEntry("""
-main() {
- while (true);
-}
-""", """
-function() {
- while (true)
- ;
-}"""),
- const TestEntry("""
-foo(a) => a;
-
-main() {
- while (true) {
- l: while (true) {
- while (foo(true)) {
- if (foo(false)) break l;
- }
- print(1);
- }
- print(2);
- }
-}
-""", """
-function() {
- L0:
- while (true)
- while (true) {
- while (P.identical(V.foo(true), true))
- if (P.identical(V.foo(false), true)) {
- P.print(2);
- continue L0;
- }
- P.print(1);
- }
-}"""),
- const TestEntry("""
-foo(a) => a;
-
-main() {
- for (int i = 0; foo(true); i = foo(i)) {
- print(1);
- if (foo(false)) break;
- }
- print(2);
-}""", """
-function() {
- var i;
- i = 0;
- L1:
- while (true) {
- if (P.identical(V.foo(true), true)) {
- P.print(1);
- if (!P.identical(V.foo(false), true)) {
- i = V.foo(i);
- continue L1;
- }
- }
- P.print(2);
- return null;
- }
-}"""),
-const TestEntry("""
-foo(a) => a;
-
-main() {
- if (foo(true)) {
- print(1);
- } else {
- print(2);
- }
- print(3);
-}""", """
-function() {
- P.identical(V.foo(true), true) ? P.print(1) : P.print(2);
- P.print(3);
- return null;
-}"""),
-const TestEntry("""
-foo(a) => a;
-
-main() {
- if (foo(true)) {
- print(1);
- print(1);
- } else {
- print(2);
- print(2);
- }
- print(3);
-}""", """
-function() {
- if (P.identical(V.foo(true), true)) {
- P.print(1);
- P.print(1);
- } else {
- P.print(2);
- P.print(2);
- }
- P.print(3);
- return null;
-}"""),
-const TestEntry("""
-main() {
- if (1) {
- print('bad');
- } else {
- print('good');
- }
-}""","""
-function() {
- P.print("good");
- return null;
-}"""),
- const TestEntry("""
-foo() => 2;
-main() {
- if (foo()) {
- print('bad');
- } else {
- print('good');
- }
-}""","""
-function() {
- V.foo();
- P.print("good");
- return null;
-}"""),
-];

Powered by Google App Engine
This is Rietveld 408576698