Return an error if the pagesize index is invalid
authorJeannot Breton <jbreton@nvidia.com>
Wed, 24 May 2017 20:27:14 +0000 (15:27 -0500)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 26 May 2017 15:44:43 +0000 (11:44 -0400)
In verifyTexStorageVirtualPageSizeIndexError, the test call
texStorage with a VIRTUAL_PAGE_SIZE_INDEX texture parameter set
to NUM_VIRTUAL_PAGE_SIZES + 1.

However the verifyError after the texStorage expect GL_NO_ERROR.
It should be GL_INVALID_OPERATION

Affects:

KHR-GL45.sparse_texture_tests.*

Components: OpenGL

VK-GL-CTS issue: 436

Change-Id: I43d02dcbee4bbe2c81feb4a17e9fde7386375656

external/openglcts/modules/gl/gl4cSparseTextureTests.cpp

index 8cd34925e2a5b16d39fb47dc1fd28b4489406144..79b7b97d22947cf3d27a8603dcc4bdde92a44b7f 100644 (file)
@@ -1358,7 +1358,7 @@ bool SparseTextureAllocationTestCase::verifyTexStorageVirtualPageSizeIndexError(
        depth = SparseTextureUtils::getTargetDepth(target);
 
        Texture::Storage(gl, target, 1, format, 8, 8, depth);
-       if (!SparseTextureUtils::verifyError(mLog, "TexStorage", gl.getError(), GL_NO_ERROR))
+       if (!SparseTextureUtils::verifyError(mLog, "TexStorage", gl.getError(), GL_INVALID_OPERATION))
        {
                Texture::Delete(gl, texture);
                return false;