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

Side by Side Diff: tools/testing/dart/browser_controller.dart

Issue 14764010: Write debug info from browser controller (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 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 | « no previous file | no next file » | 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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 browser; 4 library browser;
5 5
6 import "dart:async"; 6 import "dart:async";
7 import "dart:core"; 7 import "dart:core";
8 import "dart:io"; 8 import "dart:io";
9 9
10 10
(...skipping 26 matching lines...) Expand all
37 37
38 /** 38 /**
39 * Id of the browser 39 * Id of the browser
40 */ 40 */
41 String id; 41 String id;
42 42
43 /** Callback that will be executed when the browser has closed */ 43 /** Callback that will be executed when the browser has closed */
44 Function onClose; 44 Function onClose;
45 45
46 /** Print everything (stdout, stderr, usageLog) whenever we add to it */ 46 /** Print everything (stdout, stderr, usageLog) whenever we add to it */
47 bool debugPrint = false; 47 bool debugPrint = true;
48 48
49 void _logEvent(String event) { 49 void _logEvent(String event) {
50 String toLog = "$this ($id) - ${new DateTime.now()}: $event \n"; 50 String toLog = "$this ($id) - ${new DateTime.now()}: $event \n";
51 if (debugPrint) print("usageLog: $toLog"); 51 if (debugPrint) print("usageLog: $toLog");
52 _usageLog.write(toLog); 52 _usageLog.write(toLog);
53 } 53 }
54 54
55 void _addStdout(String output) { 55 void _addStdout(String output) {
56 if (debugPrint) print("stdout: $output"); 56 if (debugPrint) print("stdout: $output");
57 _stdout.write(output); 57 _stdout.write(output);
(...skipping 626 matching lines...) Expand 10 before | Expand all | Expand 10 after
684 </script> 684 </script>
685 </head> 685 </head>
686 <body> 686 <body>
687 Dart test driver, number of tests: <div id="number"></div> 687 Dart test driver, number of tests: <div id="number"></div>
688 </body> 688 </body>
689 </html> 689 </html>
690 """; 690 """;
691 return driverContent; 691 return driverContent;
692 } 692 }
693 } 693 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698