diff options
Diffstat (limited to 'base')
-rw-r--r-- | base/directory_watcher_unittest.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/base/directory_watcher_unittest.cc b/base/directory_watcher_unittest.cc index 35833b6..014665c 100644 --- a/base/directory_watcher_unittest.cc +++ b/base/directory_watcher_unittest.cc @@ -332,13 +332,15 @@ TEST_F(DirectoryWatcherTest, WatchCreatedDirectory) { SetExpectedNumberOfNotifiedDelegates(1); FilePath subdir(CreateTestDirDirectoryASCII("SubDir", true)); + // Create a file inside the subdir to force Windows to fire notifications. + ASSERT_TRUE(WriteTestFile(subdir.AppendASCII("test_file"), "some content")); VerifyExpectedNumberOfNotifiedDelegates(); delegate.reset(); - // Write a file to the subdir. + // Verify that changes inside the subdir are noticed. SetExpectedNumberOfNotifiedDelegates(1); - ASSERT_TRUE(WriteTestFile(subdir.AppendASCII("test_file"), "some content")); + ASSERT_TRUE(WriteTestFile(subdir.AppendASCII("test_file"), "other content")); VerifyExpectedNumberOfNotifiedDelegates(); } |