Commit af550f78 authored by Victor Costan's avatar Victor Costan Committed by Commit Bot

Cache Storage: clang-tidy fixes to tests.

Change-Id: Ifaa1c3dfac42adfde6869b77595f70248c81b54a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2311047
Commit-Queue: Victor Costan <pwnall@chromium.org>
Reviewed-by: default avatarMarijn Kruisselbrink <mek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#790899}
parent 9823cfc1
......@@ -75,10 +75,8 @@ class CacheStorageBlobToDiskCacheTest : public testing::Test {
protected:
CacheStorageBlobToDiskCacheTest()
: task_environment_(BrowserTaskEnvironment::IO_MAINLOOP),
browser_context_(new TestBrowserContext()),
data_(kTestData),
callback_success_(false),
callback_called_(false) {}
browser_context_(std::make_unique<TestBrowserContext>()),
data_(kTestData) {}
void SetUp() override {
InitBlobStorage();
......@@ -193,8 +191,8 @@ class CacheStorageBlobToDiskCacheTest : public testing::Test {
cache_storage_blob_to_disk_cache_;
std::string data_;
bool callback_success_;
bool callback_called_;
bool callback_success_ = false;
bool callback_called_ = false;
private:
scoped_refptr<storage::QuotaManager> quota_manager_;
......
......@@ -271,8 +271,6 @@ class CacheStorageManagerTest : public testing::Test {
blob_storage_context_(nullptr),
observers_(
base::MakeRefCounted<CacheStorageContextImpl::ObserverList>()),
callback_bool_(false),
callback_error_(CacheStorageError::kSuccess),
origin1_(url::Origin::Create(GURL("http://example1.com"))),
origin2_(url::Origin::Create(GURL("http://example2.com"))) {}
......@@ -821,8 +819,8 @@ class CacheStorageManagerTest : public testing::Test {
scoped_refptr<CacheStorageManager> cache_manager_;
CacheStorageCacheHandle callback_cache_handle_;
int callback_bool_;
CacheStorageError callback_error_;
int callback_bool_ = false;
CacheStorageError callback_error_ = CacheStorageError::kSuccess;
blink::mojom::FetchAPIResponsePtr callback_cache_handle_response_;
std::vector<std::string> cache_names_;
......@@ -2432,7 +2430,7 @@ TEST_P(CacheStorageManagerTestP, SlowPutCompletesWithoutExternalRef) {
class CacheStorageQuotaClientTest : public CacheStorageManagerTest {
protected:
CacheStorageQuotaClientTest() {}
CacheStorageQuotaClientTest() = default;
void SetUp() override {
CacheStorageManagerTest::SetUp();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment