| OLD | NEW |
| 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 <set> | 5 #include <set> |
| 6 #include <string> | 6 #include <string> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 | 137 |
| 138 } // namespace | 138 } // namespace |
| 139 | 139 |
| 140 // TODO(ericu): The vast majority of this and the other FSFU subclass tests | 140 // TODO(ericu): The vast majority of this and the other FSFU subclass tests |
| 141 // could theoretically be shared. It would basically be a FSFU interface | 141 // could theoretically be shared. It would basically be a FSFU interface |
| 142 // compliance test, and only the subclass-specific bits that look into the | 142 // compliance test, and only the subclass-specific bits that look into the |
| 143 // implementation would need to be written per-subclass. | 143 // implementation would need to be written per-subclass. |
| 144 class ObfuscatedFileUtilTest : public testing::Test { | 144 class ObfuscatedFileUtilTest : public testing::Test { |
| 145 public: | 145 public: |
| 146 ObfuscatedFileUtilTest() | 146 ObfuscatedFileUtilTest() |
| 147 : message_loop_(base::MessageLoop::TYPE_IO), | 147 : origin_(GURL("http://www.example.com")), |
| 148 origin_(GURL("http://www.example.com")), | |
| 149 type_(storage::kFileSystemTypeTemporary), | 148 type_(storage::kFileSystemTypeTemporary), |
| 150 weak_factory_(this), | 149 weak_factory_(this), |
| 151 sandbox_file_system_(origin_, type_), | 150 sandbox_file_system_(origin_, type_), |
| 152 quota_status_(storage::kQuotaStatusUnknown), | 151 quota_status_(storage::kQuotaStatusUnknown), |
| 153 usage_(-1) {} | 152 usage_(-1) {} |
| 154 | 153 |
| 155 virtual void SetUp() { | 154 virtual void SetUp() { |
| 156 ASSERT_TRUE(data_dir_.CreateUniqueTempDir()); | 155 ASSERT_TRUE(data_dir_.CreateUniqueTempDir()); |
| 157 | 156 |
| 158 storage_policy_ = new MockSpecialStoragePolicy(); | 157 storage_policy_ = new MockSpecialStoragePolicy(); |
| (...skipping 2286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2445 false /* exclusive */, | 2444 false /* exclusive */, |
| 2446 true /* recursive */)); | 2445 true /* recursive */)); |
| 2447 ASSERT_EQ(base::File::FILE_ERROR_NOT_A_DIRECTORY, | 2446 ASSERT_EQ(base::File::FILE_ERROR_NOT_A_DIRECTORY, |
| 2448 ofu()->CreateDirectory(UnlimitedContext().get(), | 2447 ofu()->CreateDirectory(UnlimitedContext().get(), |
| 2449 path_in_file_in_file, | 2448 path_in_file_in_file, |
| 2450 false /* exclusive */, | 2449 false /* exclusive */, |
| 2451 true /* recursive */)); | 2450 true /* recursive */)); |
| 2452 } | 2451 } |
| 2453 | 2452 |
| 2454 } // namespace content | 2453 } // namespace content |
| OLD | NEW |