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

Unified Diff: test/cctest/test-thread-termination.cc

Issue 11970009: Make the Isolate parameter mandatory in Locker and Unlocker classes. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased. Added TODO. Created 7 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
« no previous file with comments | « test/cctest/test-lockers.cc ('k') | test/cctest/test-threads.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-thread-termination.cc
diff --git a/test/cctest/test-thread-termination.cc b/test/cctest/test-thread-termination.cc
index cebabaa97e84fe0076da552d5cd6bd435f14f7bc..7712a2cdbb12f23974687cc73ec2b652a579fd55 100644
--- a/test/cctest/test-thread-termination.cc
+++ b/test/cctest/test-thread-termination.cc
@@ -202,7 +202,7 @@ class LoopingThread : public v8::internal::Thread {
public:
LoopingThread() : Thread("LoopingThread") { }
void Run() {
- v8::Locker locker;
+ v8::Locker locker(CcTest::default_isolate());
v8::HandleScope scope;
v8_thread_id_ = v8::V8::GetCurrentThreadId();
v8::Handle<v8::ObjectTemplate> global =
@@ -228,7 +228,7 @@ class LoopingThread : public v8::internal::Thread {
// from another thread when using Lockers and preemption.
TEST(TerminateMultipleV8ThreadsDefaultIsolate) {
{
- v8::Locker locker;
+ v8::Locker locker(CcTest::default_isolate());
v8::V8::Initialize();
v8::Locker::StartPreemption(1);
semaphore = v8::internal::OS::CreateSemaphore(0);
@@ -246,7 +246,7 @@ TEST(TerminateMultipleV8ThreadsDefaultIsolate) {
semaphore->Wait();
}
{
- v8::Locker locker;
+ v8::Locker locker(CcTest::default_isolate());
for (int i = 0; i < kThreads; i++) {
v8::V8::TerminateExecution(threads[i]->GetV8ThreadId());
}
@@ -256,7 +256,7 @@ TEST(TerminateMultipleV8ThreadsDefaultIsolate) {
delete threads[i];
}
{
- v8::Locker locker;
+ v8::Locker locker(CcTest::default_isolate());
v8::Locker::StopPreemption();
}
@@ -372,4 +372,3 @@ TEST(TerminateAndReenterFromThreadItself) {
"f()"))->Run()->IsTrue());
context.Dispose();
}
-
« no previous file with comments | « test/cctest/test-lockers.cc ('k') | test/cctest/test-threads.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698