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

Side by Side Diff: Source/bindings/core/v8/ScriptPromisePropertyTest.cpp

Issue 1097443004: Oilpan: rename GCState and GCReason values to reflect function only. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | Source/bindings/core/v8/V8GCController.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "config.h" 5 #include "config.h"
6 #include "bindings/core/v8/ScriptPromiseProperty.h" 6 #include "bindings/core/v8/ScriptPromiseProperty.h"
7 7
8 #include "bindings/core/v8/DOMWrapperWorld.h" 8 #include "bindings/core/v8/DOMWrapperWorld.h"
9 #include "bindings/core/v8/ScriptFunction.h" 9 #include "bindings/core/v8/ScriptFunction.h"
10 #include "bindings/core/v8/ScriptPromise.h" 10 #include "bindings/core/v8/ScriptPromise.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 DOMWrapperWorld& mainWorld() { return mainScriptState()->world(); } 142 DOMWrapperWorld& mainWorld() { return mainScriptState()->world(); }
143 ScriptState* otherScriptState() { return m_otherScriptState.get(); } 143 ScriptState* otherScriptState() { return m_otherScriptState.get(); }
144 DOMWrapperWorld& otherWorld() { return m_otherScriptState->world(); } 144 DOMWrapperWorld& otherWorld() { return m_otherScriptState->world(); }
145 ScriptState* currentScriptState() { return ScriptState::current(isolate()); } 145 ScriptState* currentScriptState() { return ScriptState::current(isolate()); }
146 146
147 virtual void destroyContext() 147 virtual void destroyContext()
148 { 148 {
149 m_page.clear(); 149 m_page.clear();
150 m_otherScriptState.clear(); 150 m_otherScriptState.clear();
151 gc(); 151 gc();
152 Heap::collectGarbage(ThreadState::HeapPointersOnStack, ThreadState::GCWi thSweep, Heap::ForcedGCForTesting); 152 Heap::collectGarbage(ThreadState::HeapPointersOnStack, ThreadState::GCWi thSweep, Heap::ForcedGC);
153 } 153 }
154 154
155 void gc() { V8GCController::collectGarbage(v8::Isolate::GetCurrent()); } 155 void gc() { V8GCController::collectGarbage(v8::Isolate::GetCurrent()); }
156 156
157 v8::Handle<v8::Function> notReached(ScriptState* scriptState) { return NotRe ached::createFunction(scriptState); } 157 v8::Handle<v8::Function> notReached(ScriptState* scriptState) { return NotRe ached::createFunction(scriptState); }
158 v8::Handle<v8::Function> stub(ScriptState* scriptState, ScriptValue& value, size_t& callCount) { return StubFunction::createFunction(scriptState, value, cal lCount); } 158 v8::Handle<v8::Function> stub(ScriptState* scriptState, ScriptValue& value, size_t& callCount) { return StubFunction::createFunction(scriptState, value, cal lCount); }
159 159
160 template <typename T> 160 template <typename T>
161 ScriptValue wrap(DOMWrapperWorld& world, const T& value) 161 ScriptValue wrap(DOMWrapperWorld& world, const T& value)
162 { 162 {
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
546 { 546 {
547 test(String("hello"), "hello", __FILE__, __LINE__); 547 test(String("hello"), "hello", __FILE__, __LINE__);
548 } 548 }
549 549
550 TEST_F(ScriptPromisePropertyNonScriptWrappableResolutionTargetTest, ResolveWithI nteger) 550 TEST_F(ScriptPromisePropertyNonScriptWrappableResolutionTargetTest, ResolveWithI nteger)
551 { 551 {
552 test(-1, "-1", __FILE__, __LINE__); 552 test(-1, "-1", __FILE__, __LINE__);
553 } 553 }
554 554
555 } // namespace 555 } // namespace
OLDNEW
« no previous file with comments | « no previous file | Source/bindings/core/v8/V8GCController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698