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 <list> | 5 #include <list> |
6 #include <map> | 6 #include <map> |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 | 141 |
142 class QuotaTemporaryStorageEvictorTest : public testing::Test { | 142 class QuotaTemporaryStorageEvictorTest : public testing::Test { |
143 public: | 143 public: |
144 QuotaTemporaryStorageEvictorTest() | 144 QuotaTemporaryStorageEvictorTest() |
145 : num_get_usage_and_quota_for_eviction_(0), | 145 : num_get_usage_and_quota_for_eviction_(0), |
146 ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) {} | 146 ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) {} |
147 | 147 |
148 void SetUp() { | 148 void SetUp() { |
149 quota_eviction_handler_.reset(new MockQuotaEvictionHandler(this)); | 149 quota_eviction_handler_.reset(new MockQuotaEvictionHandler(this)); |
150 | 150 |
151 // Run multiple evictions in a single RunAllPending() when interval_ms == 0 | 151 // Run multiple evictions in a single RunUntilIdle() when interval_ms == 0 |
152 temporary_storage_evictor_.reset(new QuotaTemporaryStorageEvictor( | 152 temporary_storage_evictor_.reset(new QuotaTemporaryStorageEvictor( |
153 quota_eviction_handler_.get(), 0)); | 153 quota_eviction_handler_.get(), 0)); |
154 } | 154 } |
155 | 155 |
156 void TearDown() { | 156 void TearDown() { |
157 temporary_storage_evictor_.reset(); | 157 temporary_storage_evictor_.reset(); |
158 quota_eviction_handler_.reset(); | 158 quota_eviction_handler_.reset(); |
159 MessageLoop::current()->RunAllPending(); | 159 MessageLoop::current()->RunUntilIdle(); |
160 } | 160 } |
161 | 161 |
162 void TaskForRepeatedEvictionTest( | 162 void TaskForRepeatedEvictionTest( |
163 const std::pair<GURL, int64>& origin_to_be_added, | 163 const std::pair<GURL, int64>& origin_to_be_added, |
164 const GURL& origin_to_be_accessed, | 164 const GURL& origin_to_be_accessed, |
165 int expected_usage_after_first, | 165 int expected_usage_after_first, |
166 int expected_usage_after_second) { | 166 int expected_usage_after_second) { |
167 EXPECT_GE(4, num_get_usage_and_quota_for_eviction_); | 167 EXPECT_GE(4, num_get_usage_and_quota_for_eviction_); |
168 switch (num_get_usage_and_quota_for_eviction_) { | 168 switch (num_get_usage_and_quota_for_eviction_) { |
169 case 2: | 169 case 2: |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 | 233 |
234 TEST_F(QuotaTemporaryStorageEvictorTest, SimpleEvictionTest) { | 234 TEST_F(QuotaTemporaryStorageEvictorTest, SimpleEvictionTest) { |
235 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 3000); | 235 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 3000); |
236 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 200); | 236 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 200); |
237 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 500); | 237 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 500); |
238 quota_eviction_handler()->set_quota(4000); | 238 quota_eviction_handler()->set_quota(4000); |
239 quota_eviction_handler()->set_available_space(1000000000); | 239 quota_eviction_handler()->set_available_space(1000000000); |
240 EXPECT_EQ(3000 + 200 + 500, quota_eviction_handler()->GetUsage()); | 240 EXPECT_EQ(3000 + 200 + 500, quota_eviction_handler()->GetUsage()); |
241 set_repeated_eviction(false); | 241 set_repeated_eviction(false); |
242 temporary_storage_evictor()->Start(); | 242 temporary_storage_evictor()->Start(); |
243 MessageLoop::current()->RunAllPending(); | 243 MessageLoop::current()->RunUntilIdle(); |
244 EXPECT_EQ(200 + 500, quota_eviction_handler()->GetUsage()); | 244 EXPECT_EQ(200 + 500, quota_eviction_handler()->GetUsage()); |
245 | 245 |
246 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 246 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
247 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 247 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
248 EXPECT_EQ(1, statistics().num_evicted_origins); | 248 EXPECT_EQ(1, statistics().num_evicted_origins); |
249 EXPECT_EQ(1, statistics().num_eviction_rounds); | 249 EXPECT_EQ(1, statistics().num_eviction_rounds); |
250 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); | 250 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); |
251 } | 251 } |
252 | 252 |
253 TEST_F(QuotaTemporaryStorageEvictorTest, MultipleEvictionTest) { | 253 TEST_F(QuotaTemporaryStorageEvictorTest, MultipleEvictionTest) { |
254 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 20); | 254 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 20); |
255 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 2900); | 255 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 2900); |
256 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 450); | 256 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 450); |
257 quota_eviction_handler()->AddOrigin(GURL("http://www.w.com"), 400); | 257 quota_eviction_handler()->AddOrigin(GURL("http://www.w.com"), 400); |
258 quota_eviction_handler()->set_quota(4000); | 258 quota_eviction_handler()->set_quota(4000); |
259 quota_eviction_handler()->set_available_space(1000000000); | 259 quota_eviction_handler()->set_available_space(1000000000); |
260 EXPECT_EQ(20 + 2900 + 450 + 400, quota_eviction_handler()->GetUsage()); | 260 EXPECT_EQ(20 + 2900 + 450 + 400, quota_eviction_handler()->GetUsage()); |
261 set_repeated_eviction(false); | 261 set_repeated_eviction(false); |
262 temporary_storage_evictor()->Start(); | 262 temporary_storage_evictor()->Start(); |
263 MessageLoop::current()->RunAllPending(); | 263 MessageLoop::current()->RunUntilIdle(); |
264 EXPECT_EQ(450 + 400, quota_eviction_handler()->GetUsage()); | 264 EXPECT_EQ(450 + 400, quota_eviction_handler()->GetUsage()); |
265 | 265 |
266 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 266 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
267 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 267 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
268 EXPECT_EQ(2, statistics().num_evicted_origins); | 268 EXPECT_EQ(2, statistics().num_evicted_origins); |
269 EXPECT_EQ(1, statistics().num_eviction_rounds); | 269 EXPECT_EQ(1, statistics().num_eviction_rounds); |
270 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); | 270 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); |
271 } | 271 } |
272 | 272 |
273 TEST_F(QuotaTemporaryStorageEvictorTest, RepeatedEvictionTest) { | 273 TEST_F(QuotaTemporaryStorageEvictorTest, RepeatedEvictionTest) { |
(...skipping 11 matching lines...) Expand all Loading... |
285 quota_eviction_handler()->set_quota(1000); | 285 quota_eviction_handler()->set_quota(1000); |
286 quota_eviction_handler()->set_available_space(1000000000); | 286 quota_eviction_handler()->set_available_space(1000000000); |
287 quota_eviction_handler()->set_task_for_get_usage_and_quota( | 287 quota_eviction_handler()->set_task_for_get_usage_and_quota( |
288 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, | 288 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, |
289 weak_factory_.GetWeakPtr(), | 289 weak_factory_.GetWeakPtr(), |
290 std::make_pair(GURL("http://www.e.com"), e_size), GURL(), | 290 std::make_pair(GURL("http://www.e.com"), e_size), GURL(), |
291 initial_total_size - d_size, | 291 initial_total_size - d_size, |
292 initial_total_size - d_size + e_size - c_size)); | 292 initial_total_size - d_size + e_size - c_size)); |
293 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); | 293 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); |
294 temporary_storage_evictor()->Start(); | 294 temporary_storage_evictor()->Start(); |
295 MessageLoop::current()->RunAllPending(); | 295 MessageLoop::current()->RunUntilIdle(); |
296 EXPECT_EQ(initial_total_size - d_size + e_size - c_size - b_size, | 296 EXPECT_EQ(initial_total_size - d_size + e_size - c_size - b_size, |
297 quota_eviction_handler()->GetUsage()); | 297 quota_eviction_handler()->GetUsage()); |
298 EXPECT_EQ(5, num_get_usage_and_quota_for_eviction()); | 298 EXPECT_EQ(5, num_get_usage_and_quota_for_eviction()); |
299 | 299 |
300 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 300 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
301 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 301 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
302 EXPECT_EQ(3, statistics().num_evicted_origins); | 302 EXPECT_EQ(3, statistics().num_evicted_origins); |
303 EXPECT_EQ(2, statistics().num_eviction_rounds); | 303 EXPECT_EQ(2, statistics().num_eviction_rounds); |
304 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); | 304 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); |
305 } | 305 } |
(...skipping 11 matching lines...) Expand all Loading... |
317 quota_eviction_handler()->AddOrigin(GURL("http://www.a.com"), a_size); | 317 quota_eviction_handler()->AddOrigin(GURL("http://www.a.com"), a_size); |
318 quota_eviction_handler()->set_quota(1000); | 318 quota_eviction_handler()->set_quota(1000); |
319 quota_eviction_handler()->set_available_space(1000000000); | 319 quota_eviction_handler()->set_available_space(1000000000); |
320 quota_eviction_handler()->set_task_for_get_usage_and_quota( | 320 quota_eviction_handler()->set_task_for_get_usage_and_quota( |
321 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, | 321 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, |
322 weak_factory_.GetWeakPtr(), std::make_pair(GURL(), 0), GURL(), | 322 weak_factory_.GetWeakPtr(), std::make_pair(GURL(), 0), GURL(), |
323 initial_total_size - d_size, initial_total_size - d_size)); | 323 initial_total_size - d_size, initial_total_size - d_size)); |
324 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); | 324 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); |
325 set_repeated_eviction(true); | 325 set_repeated_eviction(true); |
326 temporary_storage_evictor()->Start(); | 326 temporary_storage_evictor()->Start(); |
327 MessageLoop::current()->RunAllPending(); | 327 MessageLoop::current()->RunUntilIdle(); |
328 EXPECT_EQ(initial_total_size - d_size, | 328 EXPECT_EQ(initial_total_size - d_size, |
329 quota_eviction_handler()->GetUsage()); | 329 quota_eviction_handler()->GetUsage()); |
330 EXPECT_EQ(4, num_get_usage_and_quota_for_eviction()); | 330 EXPECT_EQ(4, num_get_usage_and_quota_for_eviction()); |
331 | 331 |
332 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 332 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
333 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 333 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
334 EXPECT_EQ(1, statistics().num_evicted_origins); | 334 EXPECT_EQ(1, statistics().num_evicted_origins); |
335 EXPECT_EQ(3, statistics().num_eviction_rounds); | 335 EXPECT_EQ(3, statistics().num_eviction_rounds); |
336 EXPECT_EQ(2, statistics().num_skipped_eviction_rounds); | 336 EXPECT_EQ(2, statistics().num_skipped_eviction_rounds); |
337 } | 337 } |
(...skipping 14 matching lines...) Expand all Loading... |
352 quota_eviction_handler()->set_available_space(1000000000); | 352 quota_eviction_handler()->set_available_space(1000000000); |
353 quota_eviction_handler()->set_task_for_get_usage_and_quota( | 353 quota_eviction_handler()->set_task_for_get_usage_and_quota( |
354 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, | 354 base::Bind(&QuotaTemporaryStorageEvictorTest::TaskForRepeatedEvictionTest, |
355 weak_factory_.GetWeakPtr(), | 355 weak_factory_.GetWeakPtr(), |
356 std::make_pair(GURL("http://www.e.com"), e_size), | 356 std::make_pair(GURL("http://www.e.com"), e_size), |
357 GURL("http://www.c.com"), | 357 GURL("http://www.c.com"), |
358 initial_total_size - d_size, | 358 initial_total_size - d_size, |
359 initial_total_size - d_size + e_size - b_size)); | 359 initial_total_size - d_size + e_size - b_size)); |
360 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); | 360 EXPECT_EQ(initial_total_size, quota_eviction_handler()->GetUsage()); |
361 temporary_storage_evictor()->Start(); | 361 temporary_storage_evictor()->Start(); |
362 MessageLoop::current()->RunAllPending(); | 362 MessageLoop::current()->RunUntilIdle(); |
363 EXPECT_EQ(initial_total_size - d_size + e_size - b_size - a_size, | 363 EXPECT_EQ(initial_total_size - d_size + e_size - b_size - a_size, |
364 quota_eviction_handler()->GetUsage()); | 364 quota_eviction_handler()->GetUsage()); |
365 EXPECT_EQ(5, num_get_usage_and_quota_for_eviction()); | 365 EXPECT_EQ(5, num_get_usage_and_quota_for_eviction()); |
366 | 366 |
367 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 367 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
368 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 368 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
369 EXPECT_EQ(3, statistics().num_evicted_origins); | 369 EXPECT_EQ(3, statistics().num_evicted_origins); |
370 EXPECT_EQ(2, statistics().num_eviction_rounds); | 370 EXPECT_EQ(2, statistics().num_eviction_rounds); |
371 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); | 371 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); |
372 } | 372 } |
373 | 373 |
374 TEST_F(QuotaTemporaryStorageEvictorTest, DiskSpaceNonEvictionTest) { | 374 TEST_F(QuotaTemporaryStorageEvictorTest, DiskSpaceNonEvictionTest) { |
375 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 414); | 375 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 414); |
376 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 450); | 376 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 450); |
377 quota_eviction_handler()->set_quota(10000); | 377 quota_eviction_handler()->set_quota(10000); |
378 quota_eviction_handler()->set_available_space( | 378 quota_eviction_handler()->set_available_space( |
379 default_min_available_disk_space_to_start_eviction() - 350); | 379 default_min_available_disk_space_to_start_eviction() - 350); |
380 EXPECT_EQ(414 + 450, quota_eviction_handler()->GetUsage()); | 380 EXPECT_EQ(414 + 450, quota_eviction_handler()->GetUsage()); |
381 reset_min_available_disk_space_to_start_eviction(); | 381 reset_min_available_disk_space_to_start_eviction(); |
382 set_repeated_eviction(false); | 382 set_repeated_eviction(false); |
383 temporary_storage_evictor()->Start(); | 383 temporary_storage_evictor()->Start(); |
384 MessageLoop::current()->RunAllPending(); | 384 MessageLoop::current()->RunUntilIdle(); |
385 EXPECT_EQ(414 + 450, quota_eviction_handler()->GetUsage()); | 385 EXPECT_EQ(414 + 450, quota_eviction_handler()->GetUsage()); |
386 | 386 |
387 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 387 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
388 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 388 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
389 EXPECT_EQ(0, statistics().num_evicted_origins); | 389 EXPECT_EQ(0, statistics().num_evicted_origins); |
390 EXPECT_EQ(1, statistics().num_eviction_rounds); | 390 EXPECT_EQ(1, statistics().num_eviction_rounds); |
391 EXPECT_EQ(1, statistics().num_skipped_eviction_rounds); | 391 EXPECT_EQ(1, statistics().num_skipped_eviction_rounds); |
392 } | 392 } |
393 | 393 |
394 TEST_F(QuotaTemporaryStorageEvictorTest, DiskSpaceEvictionTest) { | 394 TEST_F(QuotaTemporaryStorageEvictorTest, DiskSpaceEvictionTest) { |
395 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 294); | 395 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 294); |
396 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 120); | 396 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 120); |
397 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 150); | 397 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 150); |
398 quota_eviction_handler()->AddOrigin(GURL("http://www.w.com"), 300); | 398 quota_eviction_handler()->AddOrigin(GURL("http://www.w.com"), 300); |
399 quota_eviction_handler()->set_quota(10000); | 399 quota_eviction_handler()->set_quota(10000); |
400 quota_eviction_handler()->set_available_space( | 400 quota_eviction_handler()->set_available_space( |
401 default_min_available_disk_space_to_start_eviction() - 350); | 401 default_min_available_disk_space_to_start_eviction() - 350); |
402 EXPECT_EQ(294 + 120 + 150 + 300, quota_eviction_handler()->GetUsage()); | 402 EXPECT_EQ(294 + 120 + 150 + 300, quota_eviction_handler()->GetUsage()); |
403 set_min_available_disk_space_to_start_eviction( | 403 set_min_available_disk_space_to_start_eviction( |
404 default_min_available_disk_space_to_start_eviction()); | 404 default_min_available_disk_space_to_start_eviction()); |
405 set_repeated_eviction(false); | 405 set_repeated_eviction(false); |
406 temporary_storage_evictor()->Start(); | 406 temporary_storage_evictor()->Start(); |
407 MessageLoop::current()->RunAllPending(); | 407 MessageLoop::current()->RunUntilIdle(); |
408 EXPECT_EQ(150 + 300, quota_eviction_handler()->GetUsage()); | 408 EXPECT_EQ(150 + 300, quota_eviction_handler()->GetUsage()); |
409 | 409 |
410 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); | 410 EXPECT_EQ(0, statistics().num_errors_on_evicting_origin); |
411 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); | 411 EXPECT_EQ(0, statistics().num_errors_on_getting_usage_and_quota); |
412 EXPECT_EQ(2, statistics().num_evicted_origins); | 412 EXPECT_EQ(2, statistics().num_evicted_origins); |
413 EXPECT_EQ(1, statistics().num_eviction_rounds); | 413 EXPECT_EQ(1, statistics().num_eviction_rounds); |
414 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); | 414 EXPECT_EQ(0, statistics().num_skipped_eviction_rounds); |
415 } | 415 } |
416 | 416 |
417 TEST_F(QuotaTemporaryStorageEvictorTest, UnlimitedExclusionEvictionTest) { | 417 TEST_F(QuotaTemporaryStorageEvictorTest, UnlimitedExclusionEvictionTest) { |
418 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 3000); | 418 quota_eviction_handler()->AddOrigin(GURL("http://www.z.com"), 3000); |
419 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 200); | 419 quota_eviction_handler()->AddOrigin(GURL("http://www.y.com"), 200); |
420 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 500000); | 420 quota_eviction_handler()->AddOrigin(GURL("http://www.x.com"), 500000); |
421 quota_eviction_handler()->set_unlimited_usage(500000); | 421 quota_eviction_handler()->set_unlimited_usage(500000); |
422 quota_eviction_handler()->set_quota(5000); | 422 quota_eviction_handler()->set_quota(5000); |
423 quota_eviction_handler()->set_available_space(1000000000); | 423 quota_eviction_handler()->set_available_space(1000000000); |
424 EXPECT_EQ(3000 + 200 + 500000, quota_eviction_handler()->GetUsage()); | 424 EXPECT_EQ(3000 + 200 + 500000, quota_eviction_handler()->GetUsage()); |
425 set_repeated_eviction(false); | 425 set_repeated_eviction(false); |
426 temporary_storage_evictor()->Start(); | 426 temporary_storage_evictor()->Start(); |
427 MessageLoop::current()->RunAllPending(); | 427 MessageLoop::current()->RunUntilIdle(); |
428 // Nothing should have been evicted. | 428 // Nothing should have been evicted. |
429 EXPECT_EQ(3000 + 200 + 500000, quota_eviction_handler()->GetUsage()); | 429 EXPECT_EQ(3000 + 200 + 500000, quota_eviction_handler()->GetUsage()); |
430 } | 430 } |
431 | 431 |
432 } // namespace quota | 432 } // namespace quota |
OLD | NEW |