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

Side by Side Diff: gpu/command_buffer/service/common_decoder_unittest.cc

Issue 7253052: Execute all GL commands up to the put offset reported by a flush. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "gpu/command_buffer/service/common_decoder.h" 5 #include "gpu/command_buffer/service/common_decoder.h"
6 #include "gpu/command_buffer/service/cmd_buffer_engine.h" 6 #include "gpu/command_buffer/service/cmd_buffer_engine.h"
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 namespace gpu { 9 namespace gpu {
10 10
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
549 cmd.Init(kBucketId, sizeof(kData) + 1, 1, 549 cmd.Init(kBucketId, sizeof(kData) + 1, 1,
550 MockCommandBufferEngine::kValidShmId, kSomeOffsetInSharedMemory); 550 MockCommandBufferEngine::kValidShmId, kSomeOffsetInSharedMemory);
551 EXPECT_NE(error::kNoError, ExecuteCmd(cmd)); 551 EXPECT_NE(error::kNoError, ExecuteCmd(cmd));
552 552
553 // Check that it fails if the size is invalid 553 // Check that it fails if the size is invalid
554 cmd.Init(kBucketId, 0, sizeof(kData) + 1, 554 cmd.Init(kBucketId, 0, sizeof(kData) + 1,
555 MockCommandBufferEngine::kValidShmId, kSomeOffsetInSharedMemory); 555 MockCommandBufferEngine::kValidShmId, kSomeOffsetInSharedMemory);
556 EXPECT_NE(error::kNoError, ExecuteCmd(cmd)); 556 EXPECT_NE(error::kNoError, ExecuteCmd(cmd));
557 } 557 }
558 558
559 TEST_F(CommonDecoderTest, YieldScheduler) {
560 cmd::YieldScheduler cmd;
561 cmd.Init();
562 EXPECT_EQ(error::kYield, ExecuteCmd(cmd));
563 }
564
565 } // namespace gpu 559 } // namespace gpu
566 560
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/common_decoder.cc ('k') | gpu/command_buffer/service/gles2_cmd_decoder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698