aboutsummaryrefslogtreecommitdiff
path: root/common/end2end/GfxstreamEnd2EndGlTests.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'common/end2end/GfxstreamEnd2EndGlTests.cpp')
-rw-r--r--common/end2end/GfxstreamEnd2EndGlTests.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/common/end2end/GfxstreamEnd2EndGlTests.cpp b/common/end2end/GfxstreamEnd2EndGlTests.cpp
index d3dedfc2..6b6934ff 100644
--- a/common/end2end/GfxstreamEnd2EndGlTests.cpp
+++ b/common/end2end/GfxstreamEnd2EndGlTests.cpp
@@ -88,10 +88,9 @@ TEST_P(GfxstreamEnd2EndGlTest, CreateWindowSurface) {
constexpr const int width = 32;
constexpr const int height = 32;
- auto anw = CreateEmulatedANW(width, height);
- auto anwEgl = anw->asEglNativeWindowType();
+ auto anw = mAnwHelper->createNativeWindowForTesting(mGralloc.get(), width, height);
- EGLSurface surface = mGl->eglCreateWindowSurface(display, config, anwEgl, nullptr);
+ EGLSurface surface = mGl->eglCreateWindowSurface(display, config, anw, nullptr);
ASSERT_THAT(surface, Not(Eq(EGL_NO_SURFACE)));
ASSERT_THAT(mGl->eglMakeCurrent(display, surface, surface, context), IsTrue());
@@ -108,7 +107,7 @@ TEST_P(GfxstreamEnd2EndGlTest, CreateWindowSurface) {
ASSERT_THAT(mGl->eglMakeCurrent(display, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT), IsTrue());
ASSERT_THAT(mGl->eglDestroyContext(display, context), IsTrue());
ASSERT_THAT(mGl->eglDestroySurface(display, surface), IsTrue());
- anw.reset();
+ mAnwHelper->release(anw);
TearDownGuest();
}