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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder_unittest_1.cc

Issue 851503003: Update from https://crrev.com/311076 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 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
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 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include "gpu/command_buffer/common/gles2_cmd_format.h" 7 #include "gpu/command_buffer/common/gles2_cmd_format.h"
8 #include "gpu/command_buffer/common/gles2_cmd_utils.h" 8 #include "gpu/command_buffer/common/gles2_cmd_utils.h"
9 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h" 9 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h"
10 #include "gpu/command_buffer/service/cmd_buffer_engine.h" 10 #include "gpu/command_buffer/service/cmd_buffer_engine.h"
(...skipping 23 matching lines...) Expand all
34 } // namespace 34 } // namespace
35 35
36 class GLES2DecoderTest1 : public GLES2DecoderTestBase { 36 class GLES2DecoderTest1 : public GLES2DecoderTestBase {
37 public: 37 public:
38 GLES2DecoderTest1() { } 38 GLES2DecoderTest1() { }
39 }; 39 };
40 40
41 INSTANTIATE_TEST_CASE_P(Service, GLES2DecoderTest1, ::testing::Bool()); 41 INSTANTIATE_TEST_CASE_P(Service, GLES2DecoderTest1, ::testing::Bool());
42 42
43 template <> 43 template <>
44 void GLES2DecoderTestBase::SpecializedSetup<cmds::BindBufferBase, 0>(
45 bool valid) {
46 if (valid) {
47 // TODO(zmo): This might affect the states of later tests.
48 group_->AddBufferId(client_buffer_id_, kServiceBufferId);
49 }
50 };
51
52 template <>
44 void GLES2DecoderTestBase::SpecializedSetup<cmds::GenerateMipmap, 0>( 53 void GLES2DecoderTestBase::SpecializedSetup<cmds::GenerateMipmap, 0>(
45 bool valid) { 54 bool valid) {
46 DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); 55 DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId);
47 DoTexImage2D( 56 DoTexImage2D(
48 GL_TEXTURE_2D, 0, GL_RGBA, 16, 16, 0, GL_RGBA, GL_UNSIGNED_BYTE, 57 GL_TEXTURE_2D, 0, GL_RGBA, 16, 16, 0, GL_RGBA, GL_UNSIGNED_BYTE,
49 kSharedMemoryId, kSharedMemoryOffset); 58 kSharedMemoryId, kSharedMemoryOffset);
50 if (valid) { 59 if (valid) {
51 EXPECT_CALL(*gl_, GetError()) 60 EXPECT_CALL(*gl_, GetError())
52 .WillOnce(Return(GL_NO_ERROR)) 61 .WillOnce(Return(GL_NO_ERROR))
53 .WillOnce(Return(GL_NO_ERROR)) 62 .WillOnce(Return(GL_NO_ERROR))
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 .RetiresOnSaturation(); 286 .RetiresOnSaturation();
278 } 287 }
279 }; 288 };
280 289
281 290
282 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_1_autogen.h" 291 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_1_autogen.h"
283 292
284 } // namespace gles2 293 } // namespace gles2
285 } // namespace gpu 294 } // namespace gpu
286 295
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698