OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "testing/gtest/include/gtest/gtest.h" | 5 #include "testing/gtest/include/gtest/gtest.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 content::TestBrowserThreadBundle thread_bundle_; | 188 content::TestBrowserThreadBundle thread_bundle_; |
189 scoped_ptr<TestingProfile> profile_; | 189 scoped_ptr<TestingProfile> profile_; |
190 | 190 |
191 // Temporary storage to pass information back from callbacks. | 191 // Temporary storage to pass information back from callbacks. |
192 base::File::Error open_file_system_result_; | 192 base::File::Error open_file_system_result_; |
193 ScopedFileSystemInfoList file_system_info_list_; | 193 ScopedFileSystemInfoList file_system_info_list_; |
194 | 194 |
195 scoped_refptr<BrowsingDataFileSystemHelper> helper_; | 195 scoped_refptr<BrowsingDataFileSystemHelper> helper_; |
196 scoped_refptr<CannedBrowsingDataFileSystemHelper> canned_helper_; | 196 scoped_refptr<CannedBrowsingDataFileSystemHelper> canned_helper_; |
197 | 197 |
| 198 private: |
198 DISALLOW_COPY_AND_ASSIGN(BrowsingDataFileSystemHelperTest); | 199 DISALLOW_COPY_AND_ASSIGN(BrowsingDataFileSystemHelperTest); |
199 }; | 200 }; |
200 | 201 |
201 // Verifies that the BrowsingDataFileSystemHelper correctly finds the test file | 202 // Verifies that the BrowsingDataFileSystemHelper correctly finds the test file |
202 // system data, and that each file system returned contains the expected data. | 203 // system data, and that each file system returned contains the expected data. |
203 TEST_F(BrowsingDataFileSystemHelperTest, FetchData) { | 204 TEST_F(BrowsingDataFileSystemHelperTest, FetchData) { |
204 PopulateTestFileSystemData(); | 205 PopulateTestFileSystemData(); |
205 | 206 |
206 FetchFileSystems(); | 207 FetchFileSystems(); |
207 | 208 |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 // extension and devtools schemes. | 299 // extension and devtools schemes. |
299 TEST_F(BrowsingDataFileSystemHelperTest, IgnoreExtensionsAndDevTools) { | 300 TEST_F(BrowsingDataFileSystemHelperTest, IgnoreExtensionsAndDevTools) { |
300 ASSERT_TRUE(canned_helper_->empty()); | 301 ASSERT_TRUE(canned_helper_->empty()); |
301 canned_helper_->AddFileSystem(kOriginExt, kTemporary, 0); | 302 canned_helper_->AddFileSystem(kOriginExt, kTemporary, 0); |
302 ASSERT_TRUE(canned_helper_->empty()); | 303 ASSERT_TRUE(canned_helper_->empty()); |
303 canned_helper_->AddFileSystem(kOriginDevTools, kTemporary, 0); | 304 canned_helper_->AddFileSystem(kOriginDevTools, kTemporary, 0); |
304 ASSERT_TRUE(canned_helper_->empty()); | 305 ASSERT_TRUE(canned_helper_->empty()); |
305 } | 306 } |
306 | 307 |
307 } // namespace | 308 } // namespace |
OLD | NEW |