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

Unified Diff: tools/testing/dart/browser_controller.dart

Issue 17274002: Revert 24086 Update checked in binary to version 0.5.19.0 (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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
« no previous file with comments | « tools/release/version.dart ('k') | tools/testing/dart/http_server.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/browser_controller.dart
===================================================================
--- tools/testing/dart/browser_controller.dart (revision 24095)
+++ tools/testing/dart/browser_controller.dart (working copy)
@@ -234,7 +234,7 @@
void _createLaunchHTML(var path, var url) {
var file = new File("${path}/launch.html");
- var randomFile = file.openSync(mode: FileMode.WRITE);
+ var randomFile = file.openSync(FileMode.WRITE);
var content = '<script language="JavaScript">location = "$url"</script>';
randomFile.writeStringSync(content);
randomFile.close();
@@ -245,7 +245,7 @@
// Get the version and log that.
return allowPopUps().then((success) {
if (!success) {
- return new Future.value(false);
+ return new Future.immediate(false);
}
return getVersion().then((version) {
_logEvent("Got version: $version");
@@ -281,7 +281,7 @@
if (versionResult.exitCode != 0) {
_logEvent("Failed to chrome get version");
_logEvent("Make sure $binary is a valid program for running chrome");
- return new Future.value(false);
+ return new Future.immediate(false);
}
version = versionResult.stdout;
_logEvent("Got version: $version");
@@ -363,7 +363,7 @@
return _adbDevice.killAll().then((_) => true);
});
}
- return new Future.value(true);
+ return new Future.immediate(true);
}
String toString() => "chromeOnAndroid";
@@ -383,7 +383,7 @@
Future _createPreferenceFile(var path) {
var file = new File("${path.toString()}/user.js");
- var randomFile = file.openSync(mode: FileMode.WRITE);
+ var randomFile = file.openSync(FileMode.WRITE);
randomFile.writeStringSync(enablePopUp);
randomFile.writeStringSync(disableDefaultCheck);
randomFile.close();
@@ -397,7 +397,7 @@
if (versionResult.exitCode != 0) {
_logEvent("Failed to firefox get version");
_logEvent("Make sure $binary is a valid program for running firefox");
- return new Future.value(false);
+ return new Future.immediate(false);
}
version = versionResult.stdout;
_logEvent("Got version: $version");
@@ -762,8 +762,8 @@
DebugLogger.info("Handling request to: ${request.uri.path}");
if (request.uri.path.startsWith(reportPath)) {
var browserId = request.uri.path.substring(reportPath.length + 1);
- var testId =
- int.parse(request.uri.queryParameters["id"].split("=")[1]);
+ var testId = int.parse(request.queryParameters["id"].split("=")[1]);
+
handleReport(request, browserId, testId);
// handleReport will asynchroniously fetch the data and will handle
// the closing of the streams.
@@ -894,6 +894,7 @@
// Don't do anything, we will be killed shortly.
} else {
var elapsed = new Date() - start;
+ reportError('Done getting task at: ' + elapsed);
// TODO(ricow): Do something more clever here.
if (nextTask != undefined) alert('This is really bad');
// The task is send to us as:
@@ -901,7 +902,6 @@
var split = this.responseText.split('#');
var nextTask = split[0];
current_id = split[1];
- reportError('Done getting task : ' + elapsed);
did_start = false;
run(nextTask);
}
« no previous file with comments | « tools/release/version.dart ('k') | tools/testing/dart/http_server.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698