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

Side by Side Diff: gpu/command_buffer/service/mocks.h

Issue 12017032: Add calls to EnsureGPUMemoryAvailable into GLES2DecoderImpl (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 // This file contains definitions for mock objects, used for testing. 5 // This file contains definitions for mock objects, used for testing.
6 6
7 // TODO(apatrick): This file "manually" defines some mock objects. Using gMock 7 // TODO(apatrick): This file "manually" defines some mock objects. Using gMock
8 // would be definitely preferable, unfortunately it doesn't work on Windows yet. 8 // would be definitely preferable, unfortunately it doesn't work on Windows yet.
9 9
10 #ifndef GPU_COMMAND_BUFFER_SERVICE_MOCKS_H_ 10 #ifndef GPU_COMMAND_BUFFER_SERVICE_MOCKS_H_
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 private: 110 private:
111 MOCK_METHOD0(ClearBackend, void()); 111 MOCK_METHOD0(ClearBackend, void());
112 }; 112 };
113 113
114 class MockMemoryTracker : public MemoryTracker { 114 class MockMemoryTracker : public MemoryTracker {
115 public: 115 public:
116 MockMemoryTracker(); 116 MockMemoryTracker();
117 117
118 MOCK_METHOD3(TrackMemoryAllocatedChange, void( 118 MOCK_METHOD3(TrackMemoryAllocatedChange, void(
119 size_t old_size, size_t new_size, Pool pool)); 119 size_t old_size, size_t new_size, Pool pool));
120 MOCK_METHOD1(EnsureGPUMemoryAvailable, bool(size_t size_needed));
120 121
121 private: 122 private:
122 friend class ::testing::StrictMock<MockMemoryTracker>; 123 friend class ::testing::StrictMock<MockMemoryTracker>;
123 friend class base::RefCounted< ::testing::StrictMock<MockMemoryTracker> >; 124 friend class base::RefCounted< ::testing::StrictMock<MockMemoryTracker> >;
124 virtual ~MockMemoryTracker(); 125 virtual ~MockMemoryTracker();
125 }; 126 };
126 127
127 } // namespace gles2 128 } // namespace gles2
128 } // namespace gpu 129 } // namespace gpu
129 130
130 #endif // GPU_COMMAND_BUFFER_SERVICE_MOCKS_H_ 131 #endif // GPU_COMMAND_BUFFER_SERVICE_MOCKS_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/memory_tracking.h ('k') | gpu/command_buffer/service/renderbuffer_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698