Reenable @qtwebengine_createWindow tests

Closes #2121
This commit is contained in:
Florian Bruhin 2016-11-15 07:02:32 +01:00
parent 81d67f8a2c
commit d04534dc33
7 changed files with 5 additions and 23 deletions

View File

@ -17,7 +17,6 @@ markers =
qtwebengine_todo: Features still missing with QtWebEngine
qtwebengine_skip: Tests not applicable with QtWebEngine
qtwebkit_skip: Tests not applicable with QtWebKit
qtwebengine_createWindow: Tests using createWindow with QtWebEngine (QTBUG-54419)
qtwebengine_flaky: Tests which are flaky (and currently skipped) with QtWebEngine
qtwebengine_osx_xfail: Tests which fail on OS X with QtWebEngine
js_prompt: Tests needing to display a javascript prompt

View File

@ -87,6 +87,7 @@ class WebEngineView(QWebEngineView):
target = usertypes.ClickTarget.tab
elif wintype == QWebEnginePage.WebBrowserTab:
# Middle-click / Ctrl-Click with Shift
# FIXME:qtwebengine this also affects target=_blank links...
if background_tabs:
target = usertypes.ClickTarget.tab
else:

View File

@ -132,14 +132,7 @@ if not getattr(sys, 'frozen', False):
def pytest_collection_modifyitems(config, items):
"""Apply @qtwebengine_* markers; skip unittests with QUTE_BDD_WEBENGINE."""
vercheck = qtutils.version_check
qtbug_54419_fixed = ((vercheck('5.6.2') and not vercheck('5.7.0')) or
qtutils.version_check('5.7.1') or
os.environ.get('QUTE_QTBUG54419_PATCHED', ''))
markers = [
('qtwebengine_createWindow', 'Skipped because of QTBUG-54419',
pytest.mark.skipif, not qtbug_54419_fixed and config.webengine),
('qtwebengine_todo', 'QtWebEngine TODO', pytest.mark.xfail,
config.webengine),
('qtwebengine_skip', 'Skipped with QtWebEngine', pytest.mark.skipif,

View File

@ -22,7 +22,6 @@ Feature: Using hints
### Opening in current or new tab
@qtwebengine_createWindow
Scenario: Following a hint and force to open in current tab.
When I open data/hints/link_blank.html
And I hint with args "links current" and follow a
@ -30,7 +29,7 @@ Feature: Using hints
Then the following tabs should be open:
- data/hello.txt (active)
@qtwebengine_createWindow
@qtwebengine_skip: Opens in background
Scenario: Following a hint and allow to open in new tab.
When I open data/hints/link_blank.html
And I hint with args "links normal" and follow a
@ -39,7 +38,6 @@ Feature: Using hints
- data/hints/link_blank.html
- data/hello.txt (active)
@qtwebengine_createWindow
Scenario: Following a hint to link with sub-element and force to open in current tab.
When I open data/hints/link_span.html
And I run :tab-close
@ -186,13 +184,12 @@ Feature: Using hints
And I hint wht args "links normal" and follow a
Then "navigation request: url http://localhost:*/data/hello2.txt, type NavigationTypeLinkClicked, *" should be logged
@qtwebengine_createWindow
@qtwebengine_skip: Opens in new tab due to Chromium bug
Scenario: Opening a link inside a specific iframe
When I open data/hints/iframe_target.html
And I hint with args "links normal" and follow a
Then "navigation request: url http://localhost:*/data/hello.txt, type NavigationTypeLinkClicked, *" should be logged
@qtwebengine_createWindow
Scenario: Opening a link with specific target frame in a new tab
When I open data/hints/iframe_target.html
And I run :tab-only

View File

@ -48,7 +48,6 @@ Feature: Page history
Then the history file should contain:
http://localhost:(port)/status/404 Error loading page: http://localhost:(port)/status/404
@qtwebengine_createWindow
Scenario: History with invalid URL
When I open data/javascript/window_open.html
And I run :click-element id open-invalid

View File

@ -7,8 +7,6 @@ Feature: Javascript stuff
And I open data/javascript/consolelog.html
Then the javascript message "console.log works!" should be logged
# Causes segfaults...
@qtwebengine_createWindow
Scenario: Opening/Closing a window via JS
When I open data/javascript/window_open.html
And I run :tab-only
@ -18,8 +16,6 @@ Feature: Javascript stuff
And I run :click-element id close-normal
Then "Focus object changed: *" should be logged
# Causes segfaults...
@qtwebengine_createWindow
Scenario: Opening/closing a modal window via JS
When I open data/javascript/window_open.html
And I run :tab-only
@ -44,7 +40,7 @@ Feature: Javascript stuff
And I run :click-element id close-twice
Then "Requested to close * which does not exist!" should be logged
@qtwebengine_createWindow @qtwebkit_skip
@qtwebkit_skip
Scenario: Closing a JS window twice (issue 906) - qtwebengine
When I open about:blank
And I run :tab-only
@ -56,7 +52,6 @@ Feature: Javascript stuff
And I wait for "Focus object changed: *" in the log
Then no crash should happen
@qtwebengine_createWindow
Scenario: Opening window without user interaction with javascript-can-open-windows-automatically set to true
When I open data/hello.txt
And I set content -> javascript-can-open-windows-automatically to true
@ -64,7 +59,6 @@ Feature: Javascript stuff
And I run :jseval if (window.open('about:blank')) { console.log('window opened'); } else { console.log('error while opening window'); }
Then the javascript message "window opened" should be logged
@qtwebengine_createWindow
Scenario: Opening window without user interaction with javascript-can-open-windows-automatically set to false
When I open data/hello.txt
And I set content -> javascript-can-open-windows-automatically to false

View File

@ -124,11 +124,10 @@ Feature: Miscellaneous utility commands exposed to the user.
Then the page should not be scrolled
And the error "prompt-accept: This command is only allowed in prompt/yesno mode, not normal." should be shown
@qtwebengine_createWindow
Scenario: :repeat-command with mode-switching command
When I open data/hints/link_blank.html
And I run :tab-only
And I hint with args "all"
And I hint with args "all tab-fg"
And I run :leave-mode
And I run :repeat-command
And I run :follow-hint a