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

Unified Diff: base/memory/discardable_memory_unittest.cc

Issue 195863005: Use DiscardableMemoryManager on Android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert unnecessary diff in Mac implementation Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/memory/discardable_memory_manager_unittest.cc ('k') | base/memory/discardable_memory_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/memory/discardable_memory_unittest.cc
diff --git a/base/memory/discardable_memory_unittest.cc b/base/memory/discardable_memory_unittest.cc
index d4c295565508171dc471fbf07df535609523275e..5375ada4bbfd8cbfe02414eb5265a456ba4e3a63 100644
--- a/base/memory/discardable_memory_unittest.cc
+++ b/base/memory/discardable_memory_unittest.cc
@@ -6,6 +6,7 @@
#include <algorithm>
+#include "base/logging.h"
Philippe 2014/04/28 16:31:22 FYI, I will remove this stale change in the next p
#include "base/run_loop.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -47,7 +48,7 @@ TEST_P(DiscardableMemoryTest, IsNamed) {
bool IsNativeType(DiscardableMemoryType type) {
return
- type == DISCARDABLE_MEMORY_TYPE_ANDROID ||
+ type == DISCARDABLE_MEMORY_TYPE_ASHMEM ||
type == DISCARDABLE_MEMORY_TYPE_MAC;
}
@@ -91,11 +92,8 @@ TEST_P(DiscardableMemoryTest, DeleteWhileLocked) {
ASSERT_TRUE(memory);
}
-#if !defined(OS_ANDROID)
// Test forced purging.
TEST_P(DiscardableMemoryTest, Purge) {
- ASSERT_TRUE(DiscardableMemory::PurgeForTestingSupported());
-
const scoped_ptr<DiscardableMemory> memory(CreateLockedMemory(kSize));
ASSERT_TRUE(memory);
memory->Unlock();
@@ -103,7 +101,6 @@ TEST_P(DiscardableMemoryTest, Purge) {
DiscardableMemory::PurgeForTesting();
EXPECT_EQ(DISCARDABLE_MEMORY_LOCK_STATUS_PURGED, memory->Lock());
}
-#endif // !OS_ANDROID
#if !defined(NDEBUG) && !defined(OS_ANDROID)
// Death tests are not supported with Android APKs.
« no previous file with comments | « base/memory/discardable_memory_manager_unittest.cc ('k') | base/memory/discardable_memory_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698