[Piglit] [PATCH] arb_direct_state_access: adapt to spec fixes in OpenGL 4.6

Iago Toral Quiroga itoral at igalia.com
Wed Aug 9 07:27:38 UTC 2017


TextureStorage* functions should produce INVALID_OPERATION instead
of INVALID_ENUM when the target is not valid.
---
 tests/spec/arb_direct_state_access/getcompressedtextureimage.c | 2 +-
 tests/spec/arb_direct_state_access/gettextureimage-targets.c   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/spec/arb_direct_state_access/getcompressedtextureimage.c b/tests/spec/arb_direct_state_access/getcompressedtextureimage.c
index 7c4a92739..4206a4714 100644
--- a/tests/spec/arb_direct_state_access/getcompressedtextureimage.c
+++ b/tests/spec/arb_direct_state_access/getcompressedtextureimage.c
@@ -175,7 +175,7 @@ getTexImage(bool doPBO, GLenum target, GLubyte *data,
 			glTextureStorage3D(name, 1, internalformat,
 					   IMAGE_WIDTH, IMAGE_HEIGHT,
 					   num_faces);
-			pass &= piglit_check_gl_error(GL_INVALID_ENUM);
+			pass &= piglit_check_gl_error(GL_INVALID_OPERATION);
 		}
 		glTextureStorage2D(name, 1, internalformat,
 				   IMAGE_WIDTH, IMAGE_HEIGHT);
diff --git a/tests/spec/arb_direct_state_access/gettextureimage-targets.c b/tests/spec/arb_direct_state_access/gettextureimage-targets.c
index a0f48d2d2..4ebb73f59 100644
--- a/tests/spec/arb_direct_state_access/gettextureimage-targets.c
+++ b/tests/spec/arb_direct_state_access/gettextureimage-targets.c
@@ -135,7 +135,7 @@ getTexImage(bool doPBO, GLenum target, GLubyte data[][IMAGE_SIZE],
 			glTextureStorage3D(name, 1, internalformat,
 					   IMAGE_WIDTH, IMAGE_HEIGHT,
 					   num_faces);
-			pass = piglit_check_gl_error(GL_INVALID_ENUM) && pass;
+			pass = piglit_check_gl_error(GL_INVALID_OPERATION) && pass;
 		}
 		/* This is legal. */
 		glTextureStorage2D(name, 1, internalformat,
-- 
2.11.0



More information about the Piglit mailing list