Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: gpu/ipc/service/gpu_channel_unittest.cc

Issue 2778833002: Revert changes to GPU test MessageLoop type. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gpu/ipc/service/BUILD.gn ('k') | gpu/test_message_loop_type.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stdint.h> 5 #include <stdint.h>
6 6
7 #include "base/memory/shared_memory.h" 7 #include "base/memory/shared_memory.h"
8 #include "base/test/test_message_loop.h" 8 #include "base/test/test_message_loop.h"
9 #include "gpu/ipc/common/gpu_messages.h" 9 #include "gpu/ipc/common/gpu_messages.h"
10 #include "gpu/ipc/service/gpu_channel.h" 10 #include "gpu/ipc/service/gpu_channel.h"
11 #include "gpu/ipc/service/gpu_channel_manager.h" 11 #include "gpu/ipc/service/gpu_channel_manager.h"
12 #include "gpu/ipc/service/gpu_channel_test_common.h" 12 #include "gpu/ipc/service/gpu_channel_test_common.h"
13 #include "gpu/test_message_loop_type.h"
14 #include "ipc/ipc_test_sink.h" 13 #include "ipc/ipc_test_sink.h"
15 #include "ui/gl/gl_surface_stub.h" 14 #include "ui/gl/gl_surface_stub.h"
16 #include "ui/gl/init/gl_factory.h" 15 #include "ui/gl/init/gl_factory.h"
17 #include "ui/gl/test/gl_surface_test_support.h" 16 #include "ui/gl/test/gl_surface_test_support.h"
18 17
19 namespace gpu { 18 namespace gpu {
20 19
21 class GpuChannelTest : public GpuChannelTestCommon { 20 class GpuChannelTest : public GpuChannelTestCommon {
22 public: 21 public:
23 GpuChannelTest() 22 GpuChannelTest() : GpuChannelTestCommon() {}
24 : GpuChannelTestCommon(),
25 message_loop_(test::GetMessageLoopTypeForGpu()) {}
26 ~GpuChannelTest() override {} 23 ~GpuChannelTest() override {}
27 24
28 void SetUp() override { 25 void SetUp() override {
29 // We need GL bindings to actually initialize command buffers. 26 // We need GL bindings to actually initialize command buffers.
30 gl::GLSurfaceTestSupport::InitializeOneOffWithStubBindings(); 27 gl::GLSurfaceTestSupport::InitializeOneOffWithStubBindings();
31 28
32 GpuChannelTestCommon::SetUp(); 29 GpuChannelTestCommon::SetUp();
33 } 30 }
34 31
35 void TearDown() override { 32 void TearDown() override {
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after
401 EXPECT_TRUE(channel->LookupCommandBuffer(kSharedRouteId)); 398 EXPECT_TRUE(channel->LookupCommandBuffer(kSharedRouteId));
402 399
403 // Destroy the command buffers we initialized before destoying GL. 400 // Destroy the command buffers we initialized before destoying GL.
404 HandleMessage(channel, 401 HandleMessage(channel,
405 new GpuChannelMsg_DestroyCommandBuffer(kFriendlyRouteId)); 402 new GpuChannelMsg_DestroyCommandBuffer(kFriendlyRouteId));
406 HandleMessage(channel, 403 HandleMessage(channel,
407 new GpuChannelMsg_DestroyCommandBuffer(kSharedRouteId)); 404 new GpuChannelMsg_DestroyCommandBuffer(kSharedRouteId));
408 } 405 }
409 406
410 } // namespace gpu 407 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/ipc/service/BUILD.gn ('k') | gpu/test_message_loop_type.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698