| Index: third_party/WebKit/Source/platform/threading/BackgroundTaskRunnerTest.cpp
|
| diff --git a/third_party/WebKit/Source/platform/threading/BackgroundTaskRunnerTest.cpp b/third_party/WebKit/Source/platform/threading/BackgroundTaskRunnerTest.cpp
|
| index ec1e6240d6cab20bb0078569c89f15d418a56b16..25f8536203780c5f33dba07a1dfe1c9a52d8cbe7 100644
|
| --- a/third_party/WebKit/Source/platform/threading/BackgroundTaskRunnerTest.cpp
|
| +++ b/third_party/WebKit/Source/platform/threading/BackgroundTaskRunnerTest.cpp
|
| @@ -8,6 +8,8 @@
|
| #include "platform/WaitableEvent.h"
|
| #include "public/platform/WebTraceLocation.h"
|
| #include "testing/gtest/include/gtest/gtest.h"
|
| +#include "wtf/PtrUtil.h"
|
| +#include <memory>
|
|
|
|
|
| namespace {
|
| @@ -24,7 +26,7 @@ class BackgroundTaskRunnerTest : public testing::Test {
|
|
|
| TEST_F(BackgroundTaskRunnerTest, RunShortTaskOnBackgroundThread)
|
| {
|
| - OwnPtr<WaitableEvent> doneEvent = adoptPtr(new WaitableEvent());
|
| + std::unique_ptr<WaitableEvent> doneEvent = wrapUnique(new WaitableEvent());
|
| BackgroundTaskRunner::postOnBackgroundThread(BLINK_FROM_HERE, threadSafeBind(&PingPongTask, AllowCrossThreadAccess(doneEvent.get())), BackgroundTaskRunner::TaskSizeShortRunningTask);
|
| // Test passes by not hanging on the following wait().
|
| doneEvent->wait();
|
| @@ -32,7 +34,7 @@ TEST_F(BackgroundTaskRunnerTest, RunShortTaskOnBackgroundThread)
|
|
|
| TEST_F(BackgroundTaskRunnerTest, RunLongTaskOnBackgroundThread)
|
| {
|
| - OwnPtr<WaitableEvent> doneEvent = adoptPtr(new WaitableEvent());
|
| + std::unique_ptr<WaitableEvent> doneEvent = wrapUnique(new WaitableEvent());
|
| BackgroundTaskRunner::postOnBackgroundThread(BLINK_FROM_HERE, threadSafeBind(&PingPongTask, AllowCrossThreadAccess(doneEvent.get())), BackgroundTaskRunner::TaskSizeLongRunningTask);
|
| // Test passes by not hanging on the following wait().
|
| doneEvent->wait();
|
|
|