[ iOS Sim ] REGRESSION (r242986) Layout Test storage/indexeddb/modern/idbtransaction...
authorsihui_liu@apple.com <sihui_liu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Apr 2019 01:58:33 +0000 (01:58 +0000)
committersihui_liu@apple.com <sihui_liu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Apr 2019 01:58:33 +0000 (01:58 +0000)
https://bugs.webkit.org/show_bug.cgi?id=196357
<rdar://problem/49386836>

Reviewed by Geoffrey Garen.

Source/WebCore:

Dispatch IDBRequest event to IDBTransaction if event of IDBTransaction has not been dispatched.

Covered by existing tests.

* Modules/indexeddb/IDBRequest.cpp:
(WebCore::IDBRequest::dispatchEvent):
* Modules/indexeddb/IDBTransaction.cpp:
(WebCore::IDBTransaction::dispatchEvent):
* Modules/indexeddb/IDBTransaction.h:

LayoutTests:

* platform/ios-simulator-wk2/TestExpectations:
* platform/mac-wk2/TestExpectations:
* platform/mac/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@244674 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/platform/ios-simulator-wk2/TestExpectations
LayoutTests/platform/mac-wk2/TestExpectations
LayoutTests/platform/mac/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/Modules/indexeddb/IDBRequest.cpp
Source/WebCore/Modules/indexeddb/IDBTransaction.cpp
Source/WebCore/Modules/indexeddb/IDBTransaction.h

index b6edc57..a7fd6cd 100644 (file)
@@ -1,3 +1,15 @@
+2019-04-25  Sihui Liu  <sihui_liu@apple.com>
+
+        [ iOS Sim ] REGRESSION (r242986) Layout Test storage/indexeddb/modern/idbtransaction-objectstore-failures-private.html is a flaky failure
+        https://bugs.webkit.org/show_bug.cgi?id=196357
+        <rdar://problem/49386836>
+
+        Reviewed by Geoffrey Garen.
+
+        * platform/ios-simulator-wk2/TestExpectations:
+        * platform/mac-wk2/TestExpectations:
+        * platform/mac/TestExpectations:
+
 2019-04-25  Shawn Roberts  <sroberts@apple.com>
 
         fast/harness/render-tree-as-text-options.html Rebaselined test for windows
index a23d71a..3714c4f 100644 (file)
@@ -75,8 +75,6 @@ webkit.org/b/196112 imported/w3c/web-platform-tests/mathml/relations/css-styling
 webkit.org/b/196112 imported/w3c/web-platform-tests/mathml/relations/css-styling/mathvariant-double-struck.html [ Pass ImageOnlyFailure ]
 webkit.org/b/196112 imported/w3c/web-platform-tests/mathml/relations/css-styling/mathvariant-italic.html [ Pass ImageOnlyFailure ]
 
-webkit.org/b/196357 storage/indexeddb/modern/idbtransaction-objectstore-failures-private.html [ Pass Failure ]
-
 http/wpt/cache-storage/quota-third-party.https.html [ Slow ]
 http/wpt/fetch/response-opaque-clone.html [ Slow ]
 
index 6fae45d..d5c2a3f 100644 (file)
@@ -673,8 +673,6 @@ webkit.org/b/171763 compositing/tiling/non-active-window-tiles-size.html [ Pass
 
 webkit.org/b/171837 [ Debug ] http/tests/security/storage-blocking-loosened-plugin.html [ Pass Failure ]
 
-webkit.org/b/171862  storage/indexeddb/modern/idbtransaction-objectstore-failures.html [ Pass Failure ]
-
 webkit.org/b/171935 [ Sierra ] tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html [ Pass Failure ]
 
 webkit.org/b/171939 [ Sierra Release ] media/track/track-cue-rendering-on-resize.html [ Pass Timeout ]
index 66d0841..bcc584f 100644 (file)
@@ -1593,8 +1593,6 @@ webkit.org/b/175998 http/tests/security/mixedContent/insecure-css-with-secure-co
 
 webkit.org/b/165311 [ Sierra+ ] media/modern-media-controls/pip-support/pip-support-click.html [ Pass Failure ]
 
-webkit.org/b/176693 storage/indexeddb/modern/idbtransaction-objectstore-failures-private.html [ Pass Failure ]
-
 # User-installed font infrastructure is ony present on certain OSes.
 webkit.org/b/180062 [ Sierra HighSierra ] fast/text/user-installed-fonts/disable.html [ ImageOnlyFailure ]
 webkit.org/b/180062 fast/text/user-installed-fonts/shadow-postscript.html [ ImageOnlyFailure ]
index fce9e31..492d785 100644 (file)
@@ -1,3 +1,21 @@
+2019-04-25  Sihui Liu  <sihui_liu@apple.com>
+
+        [ iOS Sim ] REGRESSION (r242986) Layout Test storage/indexeddb/modern/idbtransaction-objectstore-failures-private.html is a flaky failure
+        https://bugs.webkit.org/show_bug.cgi?id=196357
+        <rdar://problem/49386836>
+
+        Reviewed by Geoffrey Garen.
+
+        Dispatch IDBRequest event to IDBTransaction if event of IDBTransaction has not been dispatched.
+
+        Covered by existing tests.
+
+        * Modules/indexeddb/IDBRequest.cpp:
+        (WebCore::IDBRequest::dispatchEvent):
+        * Modules/indexeddb/IDBTransaction.cpp:
+        (WebCore::IDBTransaction::dispatchEvent):
+        * Modules/indexeddb/IDBTransaction.h:
+
 2019-04-25  Chris Dumez  <cdumez@apple.com>
 
         ASSERT(scriptExecutionContext()) in Performance::resourceTimingBufferFullTimerFired()
index aa7543a..ce4f61a 100644 (file)
@@ -318,7 +318,7 @@ void IDBRequest::dispatchEvent(Event& event)
 
     if (&event == m_openDatabaseSuccessEvent)
         m_openDatabaseSuccessEvent = nullptr;
-    else if (m_transaction && !m_transaction->isFinished())
+    else if (m_transaction && !m_transaction->didDispatchAbortOrCommit())
         targets = { this, m_transaction.get(), &m_transaction->database() };
 
     m_hasPendingActivity = false;
index cb0397c..157085a 100644 (file)
@@ -641,6 +641,7 @@ void IDBTransaction::dispatchEvent(Event& event)
     auto protectedThis = makeRef(*this);
 
     EventDispatcher::dispatchEvent({ this, m_database.ptr() }, event);
+    m_didDispatchAbortOrCommit = true;
 
     if (isVersionChange()) {
         ASSERT(m_openDBRequest);
index 0313bf9..0758bd9 100644 (file)
@@ -146,6 +146,7 @@ public:
 
     bool isFinishedOrFinishing() const;
     bool isFinished() const { return m_state == IndexedDB::TransactionState::Finished; }
+    bool didDispatchAbortOrCommit() const { return m_didDispatchAbortOrCommit; }
 
     IDBClient::IDBConnectionProxy& connectionProxy();
 
@@ -261,6 +262,7 @@ private:
     RefPtr<IDBRequest> m_currentlyCompletingRequest;
 
     bool m_contextStopped { false };
+    bool m_didDispatchAbortOrCommit { false };
 };
 
 class TransactionActivator {