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

Unified Diff: base/files/file_unittest.cc

Issue 314023002: Require FLAG_WRITE when FLAG_CREATE_ALWAYS is specified (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Require FLAG_WRITE on Windows too Created 6 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 | « base/files/file_posix.cc ('k') | base/files/file_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/files/file_unittest.cc
diff --git a/base/files/file_unittest.cc b/base/files/file_unittest.cc
index 468b2a83bd1f19b9513261dda893b0cc99bc0904..cba043c332f090dc38393203eccba037030b8950 100644
--- a/base/files/file_unittest.cc
+++ b/base/files/file_unittest.cc
@@ -78,7 +78,7 @@ TEST(FileTest, Create) {
{
// Create or overwrite a file.
File file(file_path,
- base::File::FLAG_CREATE_ALWAYS | base::File::FLAG_READ);
+ base::File::FLAG_CREATE_ALWAYS | base::File::FLAG_WRITE);
EXPECT_TRUE(file.IsValid());
EXPECT_TRUE(file.created());
EXPECT_EQ(base::File::FILE_OK, file.error_details());
« no previous file with comments | « base/files/file_posix.cc ('k') | base/files/file_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698