summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJüri Valdmann <juri.valdmann@qt.io>2019-01-17 15:22:01 +0100
committerJüri Valdmann <juri.valdmann@qt.io>2019-02-05 14:15:20 +0000
commit68733d4fb913255fba47b1f7190cf85ad57e6541 (patch)
treeddfdcd4322c948cc557fe1144e3a81a03c36288e /tests
parent5bbf6c89b36a19484a9915943041740ef1bf8931 (diff)
tst_origins: Don't create SharedWorkers from unregistered scheme
Triggers DCHECK in content::SharedWorkerInstance::Matches on CI. According to the DCHECK, SharedWorkers cannot be constructed from unique origins (worker and constructor page need to be same-origin and unique origins are never same-origin with anything). In release builds the construction will just fail as expected. The DCHECK is only triggered if at least one other active SharedWorker already exists in the same storage partition. The reason it only happens on CI might be that the previous renderer process is not torn down fast enough and the previous SharedWorker remains active. Change-Id: I0906e1b5c85587df67b768ef022386d599ce9541 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/widgets/origins/tst_origins.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/tests/auto/widgets/origins/tst_origins.cpp b/tests/auto/widgets/origins/tst_origins.cpp
index 4e415af90..59cbdae13 100644
--- a/tests/auto/widgets/origins/tst_origins.cpp
+++ b/tests/auto/widgets/origins/tst_origins.cpp
@@ -640,10 +640,7 @@ void tst_Origins::sharedWorker()
QTRY_VERIFY(eval(QSL("done")).toBool());
QCOMPARE(eval(QSL("result")), QVariant(42));
- // Even unregistered schemes can create SharedWorkers.
- QVERIFY(load(QSL("tst:/resources/sharedWorker.html")));
- QTRY_VERIFY(eval(QSL("done")).toBool());
- QCOMPARE(eval(QSL("result")), QVariant(42));
+ // Unregistered schemes should not create SharedWorkers.
QVERIFY(load(QSL("PathSyntax:/resources/sharedWorker.html")));
QTRY_VERIFY(eval(QSL("done")).toBool());