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

Side by Side Diff: content/browser/fileapi/blob_url_request_job_unittest.cc

Issue 508683002: Remove implicit conversions from scoped_refptr to T* in content/browser/fileapi/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/fileapi/file_system_file_stream_reader_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/bind.h" 6 #include "base/bind.h"
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/files/scoped_temp_dir.h" 9 #include "base/files/scoped_temp_dir.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 const char* buf, int buf_size, 141 const char* buf, int buf_size,
142 base::Time* modification_time) { 142 base::Time* modification_time) {
143 storage::FileSystemURL url = 143 storage::FileSystemURL url =
144 file_system_context_->CreateCrackedFileSystemURL( 144 file_system_context_->CreateCrackedFileSystemURL(
145 GURL(kFileSystemURLOrigin), 145 GURL(kFileSystemURLOrigin),
146 kFileSystemType, 146 kFileSystemType,
147 base::FilePath().AppendASCII(filename)); 147 base::FilePath().AppendASCII(filename));
148 148
149 ASSERT_EQ(base::File::FILE_OK, 149 ASSERT_EQ(base::File::FILE_OK,
150 content::AsyncFileTestHelper::CreateFileWithData( 150 content::AsyncFileTestHelper::CreateFileWithData(
151 file_system_context_, url, buf, buf_size)); 151 file_system_context_.get(), url, buf, buf_size));
152 152
153 base::File::Info file_info; 153 base::File::Info file_info;
154 ASSERT_EQ(base::File::FILE_OK, 154 ASSERT_EQ(base::File::FILE_OK,
155 content::AsyncFileTestHelper::GetMetadata( 155 content::AsyncFileTestHelper::GetMetadata(
156 file_system_context_, url, &file_info)); 156 file_system_context_.get(), url, &file_info));
157 if (modification_time) 157 if (modification_time)
158 *modification_time = file_info.last_modified; 158 *modification_time = file_info.last_modified;
159 } 159 }
160 160
161 void OnValidateFileSystem(const GURL& root, 161 void OnValidateFileSystem(const GURL& root,
162 const std::string& name, 162 const std::string& name,
163 base::File::Error result) { 163 base::File::Error result) {
164 ASSERT_EQ(base::File::FILE_OK, result); 164 ASSERT_EQ(base::File::FILE_OK, result);
165 ASSERT_TRUE(root.is_valid()); 165 ASSERT_TRUE(root.is_valid());
166 file_system_root_url_ = root; 166 file_system_root_url_ = root;
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 EXPECT_TRUE(request_->response_headers()->GetMimeType(&content_type)); 408 EXPECT_TRUE(request_->response_headers()->GetMimeType(&content_type));
409 EXPECT_EQ(kTestContentType, content_type); 409 EXPECT_EQ(kTestContentType, content_type);
410 void* iter = NULL; 410 void* iter = NULL;
411 std::string content_disposition; 411 std::string content_disposition;
412 EXPECT_TRUE(request_->response_headers()->EnumerateHeader( 412 EXPECT_TRUE(request_->response_headers()->EnumerateHeader(
413 &iter, "Content-Disposition", &content_disposition)); 413 &iter, "Content-Disposition", &content_disposition));
414 EXPECT_EQ(kTestContentDisposition, content_disposition); 414 EXPECT_EQ(kTestContentDisposition, content_disposition);
415 } 415 }
416 416
417 } // namespace content 417 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/fileapi/file_system_file_stream_reader_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698