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

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

Issue 429453010: Drop V8RecursionScope dependency on ExecutionContext (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Reorder cleanup methods per haraken Created 6 years, 3 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 | « Source/modules/indexeddb/IDBTransaction.cpp ('k') | Source/modules/indexeddb/InspectorIndexedDBAgent.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/indexeddb/IDBTransactionTest.cpp
diff --git a/Source/modules/indexeddb/IDBTransactionTest.cpp b/Source/modules/indexeddb/IDBTransactionTest.cpp
index 0235329ca762eb30202a7293a41045fd3336dd6c..7342d23e8c4cdbfdeea6c720ec5f7918c6347b0a 100644
--- a/Source/modules/indexeddb/IDBTransactionTest.cpp
+++ b/Source/modules/indexeddb/IDBTransactionTest.cpp
@@ -35,7 +35,6 @@
#include "core/dom/Document.h"
#include "modules/indexeddb/IDBDatabase.h"
#include "modules/indexeddb/IDBDatabaseCallbacks.h"
-#include "modules/indexeddb/IDBPendingTransactionMonitor.h"
#include "platform/SharedBuffer.h"
#include "public/platform/WebIDBDatabase.h"
#include <gtest/gtest.h>
@@ -62,6 +61,11 @@ public:
ScriptState* scriptState() const { return m_scope.scriptState(); }
ExecutionContext* executionContext() { return m_scope.scriptState()->executionContext(); }
+ void deactivateNewTransactions()
+ {
+ V8PerIsolateData::from(isolate())->ensureIDBPendingTransactionMonitor()->deactivateNewTransactions();
+ }
+
private:
V8TestingScope m_scope;
RefPtrWillBePersistent<ExecutionContext> m_executionContext;
@@ -105,7 +109,7 @@ TEST_F(IDBTransactionTest, EnsureLifetime)
EXPECT_EQ(1u, set.size());
Persistent<IDBRequest> request = IDBRequest::create(scriptState(), IDBAny::createUndefined(), transaction.get());
- IDBPendingTransactionMonitor::from(*executionContext()).deactivateNewTransactions();
+ deactivateNewTransactions();
Heap::collectAllGarbage();
EXPECT_EQ(1u, set.size());
@@ -134,7 +138,7 @@ TEST_F(IDBTransactionTest, TransactionFinish)
Heap::collectAllGarbage();
EXPECT_EQ(1u, set.size());
- IDBPendingTransactionMonitor::from(*executionContext()).deactivateNewTransactions();
+ deactivateNewTransactions();
Heap::collectAllGarbage();
EXPECT_EQ(1u, set.size());
« no previous file with comments | « Source/modules/indexeddb/IDBTransaction.cpp ('k') | Source/modules/indexeddb/InspectorIndexedDBAgent.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698