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

Unified Diff: utils/pub/io.dart

Issue 10825422: Don't pollute repo with temp dirs for pub tests. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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 | « no previous file | utils/tests/pub/test_pub.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/io.dart
diff --git a/utils/pub/io.dart b/utils/pub/io.dart
index 06ac7df1c972e7817893abd288010c0cdc0f866f..e9c19f9383521efa4a3cc0307b1f0559057410f3 100644
--- a/utils/pub/io.dart
+++ b/utils/pub/io.dart
@@ -172,10 +172,11 @@ Future<Directory> ensureDir(path) {
/**
* Creates a temp directory whose name will be based on [dir] with a unique
- * suffix appended to it. Returns a [Future] that completes when the directory
- * is created.
+ * suffix appended to it. If [dir] is not provided, a temp directory will be
+ * created in a platform-dependent temporary location. Returns a [Future] that
+ * completes when the directory is created.
*/
-Future<Directory> createTempDir(dir) {
+Future<Directory> createTempDir([dir = '']) {
dir = _getDirectory(dir);
return dir.createTemp();
}
« no previous file with comments | « no previous file | utils/tests/pub/test_pub.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698