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

Side by Side Diff: base/files/file_path_watcher_browsertest.cc

Issue 8508012: Mark FilePathWatcherTest.DisappearingDirectory as flaky. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/files/file_path_watcher.h" 5 #include "base/files/file_path_watcher.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #if defined(OS_WIN) 9 #if defined(OS_WIN)
10 #include <windows.h> 10 #include <windows.h>
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 VLOG(1) << "Create File"; 365 VLOG(1) << "Create File";
366 ASSERT_TRUE(WriteFile(file, "content")); 366 ASSERT_TRUE(WriteFile(file, "content"));
367 VLOG(1) << "Waiting for file creation"; 367 VLOG(1) << "Waiting for file creation";
368 ASSERT_TRUE(WaitForEvents()); 368 ASSERT_TRUE(WaitForEvents());
369 369
370 ASSERT_TRUE(WriteFile(file, "content v2")); 370 ASSERT_TRUE(WriteFile(file, "content v2"));
371 VLOG(1) << "Waiting for file modification"; 371 VLOG(1) << "Waiting for file modification";
372 ASSERT_TRUE(WaitForEvents()); 372 ASSERT_TRUE(WaitForEvents());
373 } 373 }
374 374
375 #if defined(OS_MACOSX)
376 // http://crbug.com/85930
377 #define DisappearingDirectory FLAKY_DisappearingDirectory
378 #endif
375 TEST_F(FilePathWatcherTest, DisappearingDirectory) { 379 TEST_F(FilePathWatcherTest, DisappearingDirectory) {
376 FilePathWatcher watcher; 380 FilePathWatcher watcher;
377 FilePath dir(temp_dir_.path().AppendASCII("dir")); 381 FilePath dir(temp_dir_.path().AppendASCII("dir"));
378 FilePath file(dir.AppendASCII("file")); 382 FilePath file(dir.AppendASCII("file"));
379 ASSERT_TRUE(file_util::CreateDirectory(dir)); 383 ASSERT_TRUE(file_util::CreateDirectory(dir));
380 ASSERT_TRUE(WriteFile(file, "content")); 384 ASSERT_TRUE(WriteFile(file, "content"));
381 scoped_refptr<TestDelegate> delegate(new TestDelegate(collector())); 385 scoped_refptr<TestDelegate> delegate(new TestDelegate(collector()));
382 ASSERT_TRUE(SetupWatch(file, &watcher, delegate.get())); 386 ASSERT_TRUE(SetupWatch(file, &watcher, delegate.get()));
383 387
384 ASSERT_TRUE(file_util::Delete(dir, true)); 388 ASSERT_TRUE(file_util::Delete(dir, true));
(...skipping 399 matching lines...) Expand 10 before | Expand all | Expand 10 after
784 ASSERT_TRUE(ChangeFilePermissions(test_dir1, Execute, false)); 788 ASSERT_TRUE(ChangeFilePermissions(test_dir1, Execute, false));
785 ASSERT_TRUE(WaitForEvents()); 789 ASSERT_TRUE(WaitForEvents());
786 ASSERT_TRUE(ChangeFilePermissions(test_dir1, Execute, true)); 790 ASSERT_TRUE(ChangeFilePermissions(test_dir1, Execute, true));
787 } 791 }
788 792
789 #endif // OS_MACOSX 793 #endif // OS_MACOSX
790 } // namespace 794 } // namespace
791 795
792 } // namespace files 796 } // namespace files
793 } // namespace base 797 } // namespace base
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