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

Unified Diff: gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc

Issue 2543033002: Add texture swizzle back to command buffer. (Closed)
Patch Set: add swizzle value negative test Created 4 years 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
Index: gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc b/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
index 87c5e463e5a22068c827f96b870ed1c7aec0827b..211792c893abaadca178efbe283db3134dfadcd9 100644
--- a/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
+++ b/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
@@ -90,6 +90,15 @@ void GLES2DecoderManualInitTest::EnableDisableTest(GLenum cap,
TEST_P(GLES3DecoderTest, Basic) {
// Make sure the setup is correct for ES3.
EXPECT_TRUE(feature_info()->IsWebGL2OrES3Context());
+ EXPECT_FALSE(feature_info()->IsWebGLContext());
+ EXPECT_TRUE(feature_info()->validators()->texture_bind_target.IsValid(
+ GL_TEXTURE_3D));
+}
+
+TEST_P(WebGL2DecoderTest, Basic) {
+ // Make sure the setup is correct for WebGL2.
+ EXPECT_TRUE(feature_info()->IsWebGL2OrES3Context());
+ EXPECT_TRUE(feature_info()->IsWebGLContext());
EXPECT_TRUE(feature_info()->validators()->texture_bind_target.IsValid(
GL_TEXTURE_3D));
}
@@ -1695,6 +1704,14 @@ void GLES3DecoderTest::SetUp() {
InitDecoder(init);
}
+void WebGL2DecoderTest::SetUp() {
+ InitState init;
+ init.gl_version = "OpenGL ES 3.0";
+ init.bind_generates_resource = true;
+ init.context_type = CONTEXT_TYPE_WEBGL2;
+ InitDecoder(init);
+}
+
void GLES3DecoderWithShaderTest::SetUp() {
InitState init;
init.gl_version = "OpenGL ES 3.0";

Powered by Google App Engine
This is Rietveld 408576698