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

Unified Diff: third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp

Issue 2642113002: Worker: Reduce use of ExecutionContextTask in core/workers (Closed)
Patch Set: fix build failures Created 3 years, 11 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: third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp
diff --git a/third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp b/third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp
index f16f20c85896d3cb88d3128fe27660a234878b19..f1a13ac35914f5ca2bc45b8978d9112006394943 100644
--- a/third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp
+++ b/third_party/WebKit/Source/core/workers/DedicatedWorkerTest.cpp
@@ -13,6 +13,7 @@
#include "core/workers/WorkerThread.h"
#include "core/workers/WorkerThreadStartupData.h"
#include "core/workers/WorkerThreadTestHelper.h"
+#include "platform/CrossThreadFunctional.h"
#include "platform/testing/UnitTestHelpers.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -385,8 +386,8 @@ TEST_F(DedicatedWorkerTest, UseCounter) {
EXPECT_FALSE(UseCounter::isCounted(document(), feature1));
workerThread()->postTask(
BLINK_FROM_HERE,
- createCrossThreadTask(&DedicatedWorkerThreadForTest::countFeature,
- crossThreadUnretained(workerThread()), feature1));
+ crossThreadBind(&DedicatedWorkerThreadForTest::countFeature,
+ crossThreadUnretained(workerThread()), feature1));
testing::enterRunLoop();
EXPECT_TRUE(UseCounter::isCounted(document(), feature1));
@@ -398,8 +399,8 @@ TEST_F(DedicatedWorkerTest, UseCounter) {
EXPECT_FALSE(UseCounter::isCounted(document(), feature2));
workerThread()->postTask(
BLINK_FROM_HERE,
- createCrossThreadTask(&DedicatedWorkerThreadForTest::countDeprecation,
- crossThreadUnretained(workerThread()), feature2));
+ crossThreadBind(&DedicatedWorkerThreadForTest::countDeprecation,
+ crossThreadUnretained(workerThread()), feature2));
testing::enterRunLoop();
EXPECT_TRUE(UseCounter::isCounted(document(), feature2));
}

Powered by Google App Engine
This is Rietveld 408576698