Flutter Linux Embedder
fl_egl_image_test.cc File Reference
#include "gtest/gtest.h"
#include "flutter/shell/platform/linux/fl_egl_image.h"
#include "flutter/shell/platform/linux/testing/mock_epoxy.h"

Go to the source code of this file.

Functions

 TEST (FlEGLImageTest, Test)
 

Function Documentation

◆ TEST()

TEST ( FlEGLImageTest  ,
Test   
)

Definition at line 10 of file fl_egl_image_test.cc.

10  {
11  ::testing::NiceMock<flutter::testing::MockEpoxy> epoxy;
12 
13  EXPECT_CALL(epoxy, eglCreateImageKHR(testing::_, testing::_, testing::_,
14  testing::_, testing::_))
15  .Times(1);
16  EXPECT_CALL(epoxy, eglDestroyImageKHR(testing::_, testing::_)).Times(1);
17 
18  GLuint texture_id = 99;
19  g_autoptr(FlEGLImage) image = fl_egl_image_new(texture_id);
20  EXPECT_NE(fl_egl_image_get_image(image), EGL_NO_IMAGE_KHR);
21 }
g_autoptr(FlEngine) engine
FlEGLImage * fl_egl_image_new(GLuint texture)
Definition: fl_egl_image.cc:59
EGLImage fl_egl_image_get_image(FlEGLImage *image)
Definition: fl_egl_image.cc:68
int64_t texture_id

References fl_egl_image_get_image(), fl_egl_image_new(), g_autoptr(), and texture_id.