Index: gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc |
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc b/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc |
index ec98832aae5096f254a3abe8fa156061b9c75933..0402e32bc4bd683522059582be54aa192b252a26 100644 |
--- a/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc |
+++ b/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc |
@@ -69,7 +69,9 @@ GLES2DecoderTestBase::~GLES2DecoderTestBase() {} |
void GLES2DecoderTestBase::SetUp() { |
InitState init; |
- init.gl_version = "3.0"; |
+ // By default, test with VAO support. |
+ init.extensions = "GL_OES_vertex_array_object"; |
vmiura
2014/05/27 18:18:08
Many of the tests override this SetUp().
Could we
Zhenyao Mo
2014/05/27 21:22:49
Done.
|
+ init.gl_version = "opengl es 2.0"; |
Ken Russell (switch to Gerrit)
2014/05/27 18:24:32
Is the change of the assumed GL_VERSION in the tes
|
init.has_alpha = true; |
init.has_depth = true; |
init.request_alpha = true; |
@@ -156,7 +158,9 @@ void GLES2DecoderTestBase::InitDecoderWithCommandLine( |
group_->Initialize(mock_decoder_.get(), DisallowedFeatures())); |
if (group_->feature_info()->feature_flags().native_vertex_array_object) { |
- EXPECT_CALL(*gl_, GenVertexArraysOES(1, _)).Times(1).RetiresOnSaturation(); |
+ EXPECT_CALL(*gl_, GenVertexArraysOES(1, _)) |
+ .WillOnce(SetArgumentPointee<1>(kServiceVertexArrayId)) |
+ .RetiresOnSaturation(); |
EXPECT_CALL(*gl_, BindVertexArrayOES(_)).Times(1).RetiresOnSaturation(); |
} |
@@ -365,6 +369,12 @@ void GLES2DecoderTestBase::ResetDecoder() { |
.Times(2) |
.RetiresOnSaturation(); |
+ if (group_->feature_info()->feature_flags().native_vertex_array_object) { |
+ EXPECT_CALL(*gl_, DeleteVertexArraysOES(1, Pointee(kServiceVertexArrayId))) |
+ .Times(1) |
+ .RetiresOnSaturation(); |
+ } |
+ |
decoder_->EndDecoding(); |
decoder_->Destroy(true); |
decoder_.reset(); |