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

Unified Diff: Source/modules/indexeddb/IDBRequestTest.cpp

Issue 295163005: Remove ScriptState::current() from IDBRequest (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 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: Source/modules/indexeddb/IDBRequestTest.cpp
diff --git a/Source/modules/indexeddb/IDBRequestTest.cpp b/Source/modules/indexeddb/IDBRequestTest.cpp
index 2eb2a5b4e93225d4aff6e38990591324a44b2598..cf0bda51167c79cdefdea07df0a64235b59a4a11 100644
--- a/Source/modules/indexeddb/IDBRequestTest.cpp
+++ b/Source/modules/indexeddb/IDBRequestTest.cpp
@@ -79,6 +79,8 @@ public:
{
}
+ v8::Isolate* isolate() const { return m_scope->isolate(); }
+
ExecutionContext* executionContext()
{
return m_context.get();
@@ -92,7 +94,7 @@ private:
TEST_F(IDBRequestTest, EventsAfterStopping)
{
IDBTransaction* transaction = 0;
- RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(executionContext(), IDBAny::createUndefined(), transaction);
+ RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(ScriptState::current(isolate()), IDBAny::createUndefined(), transaction);
EXPECT_EQ(request->readyState(), "pending");
executionContext()->stopActiveDOMObjects();
@@ -111,7 +113,7 @@ TEST_F(IDBRequestTest, EventsAfterStopping)
TEST_F(IDBRequestTest, AbortErrorAfterAbort)
{
IDBTransaction* transaction = 0;
- RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(executionContext(), IDBAny::createUndefined(), transaction);
+ RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(ScriptState::current(isolate()), IDBAny::createUndefined(), transaction);
EXPECT_EQ(request->readyState(), "pending");
// Simulate the IDBTransaction having received onAbort from back end and aborting the request:
@@ -158,7 +160,7 @@ TEST_F(IDBRequestTest, ConnectionsAfterStopping)
{
OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create();
- RefPtrWillBeRawPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(executionContext(), callbacks, transactionId, version);
+ RefPtrWillBeRawPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(ScriptState::current(isolate()), callbacks, transactionId, version);
EXPECT_EQ(request->readyState(), "pending");
executionContext()->stopActiveDOMObjects();
@@ -167,7 +169,7 @@ TEST_F(IDBRequestTest, ConnectionsAfterStopping)
{
OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create();
- RefPtrWillBeRawPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(executionContext(), callbacks, transactionId, version);
+ RefPtrWillBeRawPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(ScriptState::current(isolate()), callbacks, transactionId, version);
EXPECT_EQ(request->readyState(), "pending");
executionContext()->stopActiveDOMObjects();

Powered by Google App Engine
This is Rietveld 408576698