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

Unified Diff: tests/standalone/io/file_system_watcher_test.dart

Issue 25471003: Modify tests to use Directory.systemTemp (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 3 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
Index: tests/standalone/io/file_system_watcher_test.dart
diff --git a/tests/standalone/io/file_system_watcher_test.dart b/tests/standalone/io/file_system_watcher_test.dart
index fef2d6ea333067868623bf5abb40214697cd8471..50efb25f363fd32d7c1999a8226951ce54da002a 100644
--- a/tests/standalone/io/file_system_watcher_test.dart
+++ b/tests/standalone/io/file_system_watcher_test.dart
@@ -10,7 +10,7 @@ import "package:expect/expect.dart";
void testWatchCreateFile() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
var watcher = dir.watch();
@@ -34,7 +34,7 @@ void testWatchCreateFile() {
void testWatchModifyFile() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
file.createSync();
@@ -59,7 +59,7 @@ void testWatchModifyFile() {
void testWatchMoveFile() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
file.createSync();
@@ -87,7 +87,7 @@ void testWatchMoveFile() {
void testWatchDeleteFile() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
file.createSync();
@@ -112,7 +112,7 @@ void testWatchDeleteFile() {
void testWatchOnlyModifyFile() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
var watcher = dir.watch(events: FileSystemEvent.MODIFY);
@@ -138,7 +138,7 @@ void testWatchOnlyModifyFile() {
void testMultipleEvents() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var file = new File(dir.path + '/file');
var file2 = new File(dir.path + '/file2');
@@ -185,7 +185,7 @@ void testMultipleEvents() {
void testWatchRecursive() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
if (Platform.isLinux) {
Expect.throws(() => dir.watch(recursive: true));
return;
@@ -214,7 +214,7 @@ void testWatchRecursive() {
void testWatchNonRecursive() {
- var dir = new Directory('').createTempSync();
+ var dir = Directory.createSystemTempSync('dart_file_system_watcher');
var dir2 = new Directory(dir.path + '/dir');
dir2.createSync();
var file = new File(dir.path + '/dir/file');

Powered by Google App Engine
This is Rietveld 408576698