diff options
author | dspringer@chromium.org <dspringer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-06 22:17:14 +0000 |
---|---|---|
committer | dspringer@chromium.org <dspringer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-06 22:17:14 +0000 |
commit | dc0156ac9d9f10a5a0f1cde94741b0c042c63ea6 (patch) | |
tree | 7f3dacaab478585c1116f58c7df880a58b838140 /ppapi/tests | |
parent | 0d49c28e96dafa26e14976087e7a8d03e9613b64 (diff) | |
download | chromium_src-dc0156ac9d9f10a5a0f1cde94741b0c042c63ea6.zip chromium_src-dc0156ac9d9f10a5a0f1cde94741b0c042c63ea6.tar.gz chromium_src-dc0156ac9d9f10a5a0f1cde94741b0c042c63ea6.tar.bz2 |
Add PPB_Memory_Dev to the proxy.
Includes both in- and out-of-process tests.
BUG=80610
TEST=ui_tests
Review URL: http://codereview.chromium.org/7307026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91616 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi/tests')
-rw-r--r-- | ppapi/tests/test_memory.cc | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/ppapi/tests/test_memory.cc b/ppapi/tests/test_memory.cc index 1d44db4..1dedbd4 100644 --- a/ppapi/tests/test_memory.cc +++ b/ppapi/tests/test_memory.cc @@ -30,20 +30,12 @@ void TestMemory::RunTest() { } std::string TestMemory::TestMemAlloc() { - uint32_t before_object = testing_interface_->GetLiveObjectsForInstance( - instance_->pp_instance()); - { - char* buffer = static_cast<char*>( - memory_dev_interface_->MemAlloc(kTestBufferSize)); - // Touch a couple of locations. Failure will crash the test. - buffer[0] = '1'; - buffer[kTestBufferSize - 1] = '1'; - memory_dev_interface_->MemFree(buffer); - } - - // Make sure nothing leaked. - ASSERT_TRUE(testing_interface_->GetLiveObjectsForInstance( - instance_->pp_instance()) == before_object); + char* buffer = static_cast<char*>( + memory_dev_interface_->MemAlloc(kTestBufferSize)); + // Touch a couple of locations. Failure will crash the test. + buffer[0] = '1'; + buffer[kTestBufferSize - 1] = '1'; + memory_dev_interface_->MemFree(buffer); PASS(); } |