| 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 "content/browser/renderer_host/pepper/quota_reservation.h" | 5 #include "content/browser/renderer_host/pepper/quota_reservation.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/files/file.h" | 9 #include "base/files/file.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| 11 #include "base/files/scoped_temp_dir.h" | 11 #include "base/files/scoped_temp_dir.h" |
| 12 #include "base/message_loop/message_loop.h" | 12 #include "base/message_loop/message_loop.h" |
| 13 #include "base/run_loop.h" | 13 #include "base/run_loop.h" |
| 14 #include "storage/browser/fileapi/quota/quota_reservation.h" |
| 14 #include "testing/gtest/include/gtest/gtest.h" | 15 #include "testing/gtest/include/gtest/gtest.h" |
| 15 #include "webkit/browser/fileapi/quota/quota_reservation.h" | |
| 16 | 16 |
| 17 using storage::QuotaReservationManager; | 17 using storage::QuotaReservationManager; |
| 18 | 18 |
| 19 namespace content { | 19 namespace content { |
| 20 | 20 |
| 21 namespace { | 21 namespace { |
| 22 | 22 |
| 23 const char kOrigin[] = "http://example.com"; | 23 const char kOrigin[] = "http://example.com"; |
| 24 const storage::FileSystemType kType = storage::kFileSystemTypeTemporary; | 24 const storage::FileSystemType kType = storage::kFileSystemTypeTemporary; |
| 25 | 25 |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 235 EXPECT_EQ(amount, reserved_quota); | 235 EXPECT_EQ(amount, reserved_quota); |
| 236 EXPECT_EQ(2U, file_growths.size()); | 236 EXPECT_EQ(2U, file_growths.size()); |
| 237 EXPECT_EQ(file1_size, file_growths[kFile1ID].max_written_offset); | 237 EXPECT_EQ(file1_size, file_growths[kFile1ID].max_written_offset); |
| 238 EXPECT_EQ(file3_size, file_growths[kFile3ID].max_written_offset); | 238 EXPECT_EQ(file3_size, file_growths[kFile3ID].max_written_offset); |
| 239 | 239 |
| 240 test->CloseFile(kFile1ID, ppapi::FileGrowth(file1_size, 0)); | 240 test->CloseFile(kFile1ID, ppapi::FileGrowth(file1_size, 0)); |
| 241 test->CloseFile(kFile3ID, ppapi::FileGrowth(file3_size, 0)); | 241 test->CloseFile(kFile3ID, ppapi::FileGrowth(file3_size, 0)); |
| 242 } | 242 } |
| 243 | 243 |
| 244 } // namespace content | 244 } // namespace content |
| OLD | NEW |