Commit 1fc7493e by Martin Radev Committed by Commit Bot

Fix TearDown incorrect order in ReadPixelsTest

The ANGLETest::TearDown() call was set at the beginning of the function where as it should be at the end since it destroys the context. The earlier version would not cause any crashes because the GL function calls would be ignored. BUG=angleproject:1445 TEST=angle_end2end_tests Change-Id: I187cb8fede1db4ef2bfc13ab850594c41e00b0b0 Reviewed-on: https://chromium-review.googlesource.com/362220Reviewed-by: 's avatarOlli Etuaho <oetuaho@nvidia.com> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
parent 00f6fbbe
......@@ -304,11 +304,9 @@ class CopyTexImageTestES3 : public CopyTexImageTest
{
};
/*
The test verifies that glCopyTexSubImage2D generates a GL_INVALID_OPERATION error
when the read buffer is GL_NONE.
Reference: GLES 3.0.4, Section 3.8.5 Alternate Texture Image Specification Commands
*/
// The test verifies that glCopyTexSubImage2D generates a GL_INVALID_OPERATION error
// when the read buffer is GL_NONE.
// Reference: GLES 3.0.4, Section 3.8.5 Alternate Texture Image Specification Commands
TEST_P(CopyTexImageTestES3, ReadBufferIsNone)
{
GLfloat color[] = {
......
......@@ -102,11 +102,11 @@ class ReadPixelsPBOTest : public ReadPixelsTest
void TearDown() override
{
ANGLETest::TearDown();
glDeleteBuffers(1, &mPBO);
glDeleteTextures(1, &mTexture);
glDeleteFramebuffers(1, &mFBO);
ANGLETest::TearDown();
}
GLuint mPBO;
......@@ -676,11 +676,9 @@ class ReadPixelsErrorTest : public ReadPixelsTest
GLuint mFBO;
};
/*
The test verifies that glReadPixels generates a GL_INVALID_OPERATION error
when the read buffer is GL_NONE.
Reference: GLES 3.0.4, Section 4.3.2 Reading Pixels
*/
// The test verifies that glReadPixels generates a GL_INVALID_OPERATION error
// when the read buffer is GL_NONE.
// Reference: GLES 3.0.4, Section 4.3.2 Reading Pixels
TEST_P(ReadPixelsErrorTest, ReadBufferIsNone)
{
glBindFramebuffer(GL_FRAMEBUFFER, mFBO);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment