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

Side by Side Diff: tests/benchmark_smoke/benchmark_smoke_test.dart

Issue 10191033: test renaming overhaul: step 4 client tests (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 7 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
« no previous file with comments | « tests/benchmark_smoke/benchmark_smoke.status ('k') | tests/benchmark_smoke/smoketest_lib.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #library('Smoketests_main'); 4 #library('benchmark_smoke_test');
5 5
6 #import('benchmarklib.dart'); 6 // Tests that benchmark classes used in perf testing are not broken.
7 #import('benchmark_lib.dart');
7 #import('dart:html'); 8 #import('dart:html');
8 #import('../../../../../lib/unittest/unittest.dart'); 9 #import('../../lib/unittest/unittest.dart');
9 #import('../../../../../lib/unittest/html_config.dart'); 10 #import('../../lib/unittest/html_config.dart');
10 11
11 void main() { 12 void main() {
12 useHtmlConfiguration(); 13 useHtmlConfiguration();
13 14
14 asyncTest('performanceTesting', 1, () { 15 asyncTest('performanceTesting', 1, () {
15 window.setTimeout(BENCHMARK_SUITE.runBenchmarks, 0); 16 window.setTimeout(BENCHMARK_SUITE.runBenchmarks, 0);
16 window.setTimeout(testForCompletion, 0); 17 window.setTimeout(testForCompletion, 0);
17 }); 18 });
18 } 19 }
19 20
20 testForCompletion() { 21 testForCompletion() {
21 Element element = document.query('#testResultScore'); 22 Element element = document.query('#testResultScore');
22 RegExp re = new RegExp('Score: [0-9]+'); 23 RegExp re = new RegExp('Score: [0-9]+');
23 print(element.text); 24 print(element.text);
24 Expect.isTrue(re.hasMatch(element.text)); 25 Expect.isTrue(re.hasMatch(element.text));
25 callbackDone(); 26 callbackDone();
26 } 27 }
OLDNEW
« no previous file with comments | « tests/benchmark_smoke/benchmark_smoke.status ('k') | tests/benchmark_smoke/smoketest_lib.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698