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

Side by Side Diff: runtime/tests/vm/dart/inline_stack_frame_test.dart

Issue 12212016: Remove Expect from core library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add deprecation comment for ExpectException and revert one test. Created 7 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import "package:expect/expect.dart";
6
5 // This test tries to verify that we produce the correct stack trace when 7 // This test tries to verify that we produce the correct stack trace when
6 // throwing exceptions even when functions are inlined. 8 // throwing exceptions even when functions are inlined.
7 // The test invokes a bunch of functions and then does a throw. There is a 9 // The test invokes a bunch of functions and then does a throw. There is a
8 // catch at the outer function which uses the stack trace produced to return 10 // catch at the outer function which uses the stack trace produced to return
9 // a string. The test then verifies that the stack trace contains each 11 // a string. The test then verifies that the stack trace contains each
10 // method in the invocation chain. The test is run during warmup to ensure 12 // method in the invocation chain. The test is run during warmup to ensure
11 // unoptimized code produces the correct result and is then run 13 // unoptimized code produces the correct result and is then run
12 // in a loop to ensure optimization kicks in and some inlining is done. 14 // in a loop to ensure optimization kicks in and some inlining is done.
13 // Note: it appears that functions which have a throw are not inlined (func4) 15 // Note: it appears that functions which have a throw are not inlined (func4)
14 // and functions that have try/catch in them are not optimized (func1). 16 // and functions that have try/catch in them are not optimized (func1).
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 for (var i = 0; i <= 200; i++) { 67 for (var i = 0; i <= 200; i++) {
66 result = x.func1(i); 68 result = x.func1(i);
67 } 69 }
68 Expect.isTrue(result.contains("show me inlined functions")); 70 Expect.isTrue(result.contains("show me inlined functions"));
69 Expect.isTrue(result.contains("Test.func1")); 71 Expect.isTrue(result.contains("Test.func1"));
70 Expect.isTrue(result.contains("Test.func2")); 72 Expect.isTrue(result.contains("Test.func2"));
71 Expect.isTrue(result.contains("Test.func3")); 73 Expect.isTrue(result.contains("Test.func3"));
72 Expect.isTrue(result.contains("Test.func4")); 74 Expect.isTrue(result.contains("Test.func4"));
73 Expect.isTrue(result.contains("Test.func5")); 75 Expect.isTrue(result.contains("Test.func5"));
74 } 76 }
OLDNEW
« no previous file with comments | « runtime/tests/vm/dart/byte_array_test.dart ('k') | runtime/tests/vm/dart/isolate_mirror_local_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698