| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ | 5 #ifndef COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ |
| 6 #define COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ | 6 #define COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" |
| 8 #include "components/memory_pressure/memory_pressure_calculator.h" | 9 #include "components/memory_pressure/memory_pressure_calculator.h" |
| 9 | 10 |
| 10 namespace memory_pressure { | 11 namespace memory_pressure { |
| 11 | 12 |
| 12 #if defined(MEMORY_PRESSURE_IS_POLLING) | 13 #if defined(MEMORY_PRESSURE_IS_POLLING) |
| 13 | 14 |
| 14 // A mock memory pressure calculator for unittesting. | 15 // A mock memory pressure calculator for unittesting. |
| 15 class TestMemoryPressureCalculator : public MemoryPressureCalculator { | 16 class TestMemoryPressureCalculator : public MemoryPressureCalculator { |
| 16 public: | 17 public: |
| 17 TestMemoryPressureCalculator(); | 18 TestMemoryPressureCalculator(); |
| (...skipping 22 matching lines...) Expand all Loading... |
| 40 int calls_; | 41 int calls_; |
| 41 | 42 |
| 42 DISALLOW_COPY_AND_ASSIGN(TestMemoryPressureCalculator); | 43 DISALLOW_COPY_AND_ASSIGN(TestMemoryPressureCalculator); |
| 43 }; | 44 }; |
| 44 | 45 |
| 45 #endif // defined(MEMORY_PRESSURE_IS_POLLING) | 46 #endif // defined(MEMORY_PRESSURE_IS_POLLING) |
| 46 | 47 |
| 47 } // namespace memory_pressure | 48 } // namespace memory_pressure |
| 48 | 49 |
| 49 #endif // COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ | 50 #endif // COMPONENTS_MEMORY_PRESSURE_TEST_MEMORY_PRESSURE_CALCULATOR_H_ |
| OLD | NEW |