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

Unified Diff: webkit/browser/blob/local_file_stream_reader_unittest.cc

Issue 167403002: Remove some PlatformFile uses from WebKit (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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 | webkit/browser/database/database_tracker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/browser/blob/local_file_stream_reader_unittest.cc
diff --git a/webkit/browser/blob/local_file_stream_reader_unittest.cc b/webkit/browser/blob/local_file_stream_reader_unittest.cc
index bdd1cdc592c4ff34b30ba8cfba7002815c2b4f61..43001ef5a1bc6ae6c21cd686bf90d443d0b25b1d 100644
--- a/webkit/browser/blob/local_file_stream_reader_unittest.cc
+++ b/webkit/browser/blob/local_file_stream_reader_unittest.cc
@@ -7,10 +7,10 @@
#include <string>
#include "base/file_util.h"
+#include "base/files/file.h"
#include "base/files/file_path.h"
#include "base/files/scoped_temp_dir.h"
#include "base/memory/scoped_ptr.h"
-#include "base/platform_file.h"
#include "base/run_loop.h"
#include "base/threading/thread.h"
#include "net/base/io_buffer.h"
@@ -135,14 +135,9 @@ TEST_F(LocalFileStreamReaderTest, NonExistent) {
TEST_F(LocalFileStreamReaderTest, Empty) {
base::FilePath empty_path = test_dir().AppendASCII("empty");
- base::PlatformFileError error = base::PLATFORM_FILE_OK;
- base::PlatformFile file = base::CreatePlatformFile(
- empty_path,
- base::PLATFORM_FILE_CREATE | base::PLATFORM_FILE_READ,
- NULL, &error);
- ASSERT_EQ(base::PLATFORM_FILE_OK, error);
- ASSERT_NE(base::kInvalidPlatformFileValue, file);
- base::ClosePlatformFile(file);
+ base::File file(empty_path, base::File::FLAG_CREATE | base::File::FLAG_READ);
+ ASSERT_TRUE(file.IsValid());
+ file.Close();
scoped_ptr<LocalFileStreamReader> reader(
CreateFileReader(empty_path, 0, base::Time()));
« no previous file with comments | « no previous file | webkit/browser/database/database_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698