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

Side by Side Diff: gpu/command_buffer/client/gles2_implementation_unittest.cc

Issue 706203003: Update from https://crrev.com/303153 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Tests for GLES2Implementation. 5 // Tests for GLES2Implementation.
6 6
7 #include "gpu/command_buffer/client/gles2_implementation.h" 7 #include "gpu/command_buffer/client/gles2_implementation.h"
8 8
9 #include <limits> 9 #include <limits>
10 10
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after
460 GLES2Implementation::kNoLimit)) 460 GLES2Implementation::kNoLimit))
461 return false; 461 return false;
462 } 462 }
463 463
464 EXPECT_CALL(*command_buffer_, OnFlush()).Times(1).RetiresOnSaturation(); 464 EXPECT_CALL(*command_buffer_, OnFlush()).Times(1).RetiresOnSaturation();
465 helper_->CommandBufferHelper::Finish(); 465 helper_->CommandBufferHelper::Finish();
466 ::testing::Mock::VerifyAndClearExpectations(gl_.get()); 466 ::testing::Mock::VerifyAndClearExpectations(gl_.get());
467 467
468 scoped_refptr<Buffer> ring_buffer = helper_->get_ring_buffer(); 468 scoped_refptr<Buffer> ring_buffer = helper_->get_ring_buffer();
469 commands_ = static_cast<CommandBufferEntry*>(ring_buffer->memory()) + 469 commands_ = static_cast<CommandBufferEntry*>(ring_buffer->memory()) +
470 command_buffer()->GetLastState().put_offset; 470 command_buffer()->GetPutOffset();
471 ClearCommands(); 471 ClearCommands();
472 EXPECT_TRUE(transfer_buffer_->InSync()); 472 EXPECT_TRUE(transfer_buffer_->InSync());
473 473
474 ::testing::Mock::VerifyAndClearExpectations(command_buffer()); 474 ::testing::Mock::VerifyAndClearExpectations(command_buffer());
475 return true; 475 return true;
476 } 476 }
477 477
478 void TearDown() { 478 void TearDown() {
479 Mock::VerifyAndClear(gl_.get()); 479 Mock::VerifyAndClear(gl_.get());
480 EXPECT_CALL(*command_buffer(), OnFlush()).Times(AnyNumber()); 480 EXPECT_CALL(*command_buffer(), OnFlush()).Times(AnyNumber());
(...skipping 2924 matching lines...) Expand 10 before | Expand all | Expand 10 after
3405 ContextInitOptions init_options; 3405 ContextInitOptions init_options;
3406 init_options.bind_generates_resource_client = true; 3406 init_options.bind_generates_resource_client = true;
3407 init_options.bind_generates_resource_service = false; 3407 init_options.bind_generates_resource_service = false;
3408 EXPECT_FALSE(Initialize(init_options)); 3408 EXPECT_FALSE(Initialize(init_options));
3409 } 3409 }
3410 3410
3411 #include "gpu/command_buffer/client/gles2_implementation_unittest_autogen.h" 3411 #include "gpu/command_buffer/client/gles2_implementation_unittest_autogen.h"
3412 3412
3413 } // namespace gles2 3413 } // namespace gles2
3414 } // namespace gpu 3414 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698