Disable serialization crash check on Qt 5.9
This commit is contained in:
parent
ebf3d208f6
commit
ea2d5e97e2
@ -378,16 +378,16 @@ class WebEngineHistory(browsertab.AbstractHistory):
|
||||
return self._history.canGoForward()
|
||||
|
||||
def serialize(self):
|
||||
# WORKAROUND (remove this when we bump the requirements to 5.9)
|
||||
# https://bugreports.qt.io/browse/QTBUG-59599
|
||||
if self._history.count() == 0:
|
||||
raise browsertab.WebTabError("Can't serialize page without "
|
||||
"history!")
|
||||
# WORKAROUND (FIXME: remove this when we bump the requirements to 5.9?)
|
||||
# https://github.com/qutebrowser/qutebrowser/issues/2289
|
||||
scheme = self._history.currentItem().url().scheme()
|
||||
if scheme in ['view-source', 'chrome']:
|
||||
raise browsertab.WebTabError("Can't serialize special URL!")
|
||||
if not qtutils.version_check('5.9'):
|
||||
# WORKAROUND for https://bugreports.qt.io/browse/QTBUG-59599
|
||||
if self._history.count() == 0:
|
||||
raise browsertab.WebTabError("Can't serialize page without "
|
||||
"history!")
|
||||
# WORKAROUND for
|
||||
# https://github.com/qutebrowser/qutebrowser/issues/2289
|
||||
scheme = self._history.currentItem().url().scheme()
|
||||
if scheme in ['view-source', 'chrome']:
|
||||
raise browsertab.WebTabError("Can't serialize special URL!")
|
||||
return qtutils.serialize(self._history)
|
||||
|
||||
def deserialize(self, data):
|
||||
|
@ -607,12 +607,18 @@ Feature: Tab management
|
||||
title: Test title
|
||||
|
||||
# https://github.com/qutebrowser/qutebrowser/issues/2289
|
||||
@qtwebkit_skip @qt>=5.8
|
||||
@qtwebkit_skip @qt==5.8.0
|
||||
Scenario: Cloning a tab with a special URL
|
||||
When I open chrome://gpu
|
||||
And I run :tab-clone
|
||||
Then the error "Can't serialize special URL!" should be shown
|
||||
|
||||
@qtwebkit_skip @qt>=5.9
|
||||
Scenario: Cloning a tab with a special URL (Qt 5.9)
|
||||
When I open chrome://gpu
|
||||
And I run :tab-clone
|
||||
Then no crash should happen
|
||||
|
||||
# :tab-detach
|
||||
|
||||
Scenario: Detaching a tab
|
||||
|
Loading…
Reference in New Issue
Block a user