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

Unified Diff: gpu/command_buffer/service/program_manager_unittest.cc

Issue 2378583003: Ping watchdog thread during GpuChannel destruction (Closed)
Patch Set: revert to passing via destructor Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/service/program_manager_unittest.cc
diff --git a/gpu/command_buffer/service/program_manager_unittest.cc b/gpu/command_buffer/service/program_manager_unittest.cc
index 196c979c4d67f398d599e2c25cbfa2884f8d1ca5..86e797ceb482dd3db453e620192e6fa6eb908b07 100644
--- a/gpu/command_buffer/service/program_manager_unittest.cc
+++ b/gpu/command_buffer/service/program_manager_unittest.cc
@@ -21,6 +21,7 @@
#include "gpu/command_buffer/service/gpu_service_test.h"
#include "gpu/command_buffer/service/gpu_switches.h"
#include "gpu/command_buffer/service/mocks.h"
+#include "gpu/command_buffer/service/progress_reporter_stub.h"
#include "gpu/command_buffer/service/shader_manager.h"
#include "gpu/command_buffer/service/test_helper.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -83,7 +84,8 @@ class ProgramManagerTestBase : public GpuServiceTest {
SetUpBase("2.0", "GL_EXT_framebuffer_object");
}
void TearDown() override {
- manager_->Destroy(false);
+ ProgressReporterStub progress_reporter;
+ manager_->Destroy(false, &progress_reporter);
manager_.reset();
feature_info_ = nullptr;
GpuServiceTest::TearDown();
@@ -124,7 +126,8 @@ TEST_F(ProgramManagerTest, Destroy) {
EXPECT_CALL(*gl_, DeleteProgram(kService1Id))
.Times(1)
.RetiresOnSaturation();
- manager_->Destroy(true);
+ ProgressReporterStub progress_reporter;
+ manager_->Destroy(true, &progress_reporter);
// Check the resources were released.
program1 = manager_->GetProgram(kClient1Id);
ASSERT_TRUE(program1 == NULL);
@@ -444,7 +447,8 @@ class ProgramManagerWithShaderTest : public ProgramManagerTestBase {
}
void TearDown() override {
- shader_manager_.Destroy(false);
+ ProgressReporterStub progress_reporter;
+ shader_manager_.Destroy(false, &progress_reporter);
ProgramManagerTestBase::TearDown();
}
@@ -2099,7 +2103,8 @@ class ProgramManagerWithCacheTest : public ProgramManagerTestBase {
}
void TearDown() override {
- shader_manager_.Destroy(false);
+ ProgressReporterStub progress_reporter;
+ shader_manager_.Destroy(false, &progress_reporter);
ProgramManagerTestBase::TearDown();
}

Powered by Google App Engine
This is Rietveld 408576698