1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
gpu / command_buffer / tests / gl_offscreen_surface_unittest.cc [blame]
// Copyright 2018 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
#include <GLES2/gl2extchromium.h>
#include <stdint.h>
#include "gpu/command_buffer/tests/gl_manager.h"
#include "gpu/command_buffer/tests/gl_test_utils.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace gpu {
// Test that an offscreen surface with zero size initializes correctly
TEST(OffscreenSurfaceTest, ZeroInitialSize) {
GLManager::Options options;
options.size = gfx::Size(0, 0);
options.context_type = CONTEXT_TYPE_OPENGLES2;
GLManager gl;
gl.Initialize(options);
ASSERT_TRUE(gl.IsInitialized());
gl.Destroy();
}
} // namespace gpu