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

Side by Side Diff: net/disk_cache/flash/flash_cache_test_base.h

Issue 14265009: FlashCache refactorings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More refactorings. Created 7 years, 8 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 | net/disk_cache/flash/flash_cache_test_base.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 (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 #ifndef NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_ 5 #ifndef NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_
6 #define NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_ 6 #define NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/files/scoped_temp_dir.h" 10 #include "base/files/scoped_temp_dir.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "net/disk_cache/flash/format.h"
12 #include "testing/gtest/include/gtest/gtest.h" 13 #include "testing/gtest/include/gtest/gtest.h"
13 14
15 namespace {
16
17 const int32 kNumTestSegments = 10;
18 const int32 kStorageSize = kNumTestSegments * disk_cache::kFlashSegmentSize;
19
20 } // namespace
21
14 namespace disk_cache { 22 namespace disk_cache {
15 23
16 class LogStore; 24 class LogStore;
17 class Storage;
18 25
19 } // namespace disk_cache 26 } // namespace disk_cache
20 27
21 class FlashCacheTest : public testing::Test { 28 class FlashCacheTest : public testing::Test {
22 protected: 29 protected:
23 FlashCacheTest(); 30 FlashCacheTest();
24 virtual ~FlashCacheTest(); 31 virtual ~FlashCacheTest();
25 32
26 virtual void SetUp() OVERRIDE; 33 virtual void SetUp() OVERRIDE;
27 virtual void TearDown() OVERRIDE; 34 virtual void TearDown() OVERRIDE;
28 35
29 scoped_ptr<disk_cache::LogStore> log_store_;
30 scoped_ptr<disk_cache::Storage> storage_;
31 base::ScopedTempDir temp_dir_; 36 base::ScopedTempDir temp_dir_;
32 int32 num_segments_in_storage_; 37 base::FilePath path_;
33 38
34 private: 39 private:
35 DISALLOW_COPY_AND_ASSIGN(FlashCacheTest); 40 DISALLOW_COPY_AND_ASSIGN(FlashCacheTest);
36 }; 41 };
37 42
38 #endif // NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_ 43 #endif // NET_DISK_CACHE_DISK_CACHE_FLASH_TEST_BASE_H_
OLDNEW
« no previous file with comments | « no previous file | net/disk_cache/flash/flash_cache_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698