Florian Bruhin
165504c1f2
bdd: Fix clipboard_contains_multiline
2016-05-08 22:09:19 +02:00
Florian Bruhin
b9b6f357da
Add utils.supports_selection()
2016-05-08 22:06:59 +02:00
Florian Bruhin
3e6ac28c66
Fix ;Y on systems not supporting primary selection
...
Instead we paste clipboard like we already do with some other commands
when primary selection is not supported.
Fixes #1336
2016-05-08 21:59:25 +02:00
Florian Bruhin
4d9a98a11d
Paste clipboard with :paste-primary on Windows
2016-05-08 21:18:57 +02:00
Florian Bruhin
ddc1f803c0
Clean up assertion
2016-05-08 20:01:35 +02:00
Florian Bruhin
f49cc4e901
Only keep contain tests
2016-05-08 19:57:59 +02:00
Florian Bruhin
65ed878dcf
Update copyright
2016-05-08 19:57:18 +02:00
Florian Bruhin
fdb28e4c71
Add test_sortfilter from #950
2016-05-08 19:56:41 +02:00
Florian Bruhin
f306ca9b53
Fix lint
2016-05-08 11:14:42 +02:00
Florian Bruhin
b4272975f2
Revert "Use lists instead of tuples"
...
This reverts commit eb5bfc1659
.
2016-05-08 11:09:47 +02:00
Florian Bruhin
4403f02ac5
Fix HostBlocker.on_config_changed with no datadir
2016-05-07 23:35:30 +02:00
Florian Bruhin
6d1764e732
Clear blocked hosts on start correctly
2016-05-07 23:31:35 +02:00
Florian Bruhin
f6544786c1
dict
2016-05-07 22:41:22 +02:00
Florian Bruhin
2d8bde62a5
docstring
2016-05-07 22:39:53 +02:00
Florian Bruhin
9e64e5eab4
Check CommandError exception value
2016-05-07 22:39:09 +02:00
Florian Bruhin
f4f329714d
Reformat dicts
2016-05-07 22:38:37 +02:00
Florian Bruhin
1a03388fb5
Fix docstrings
2016-05-07 22:28:06 +02:00
Florian Bruhin
eb5bfc1659
Use lists instead of tuples
2016-05-07 22:12:28 +02:00
Florian Bruhin
bc8d19f003
Fix typo
2016-05-07 22:09:43 +02:00
Florian Bruhin
2ae8ecff71
Use qapp fixture in all adblock tests
2016-05-07 22:08:55 +02:00
Florian Bruhin
7db6f52fa1
Merge branch 'test_adblock' of https://github.com/jcorentin/qutebrowser into jcorentin-test_adblock
2016-05-07 22:06:43 +02:00
Daniel Schadt
dcac832f5e
netmanager: fix crash when asking with no tab_id
...
Issue 1413
This happens when the networkmanager is used by something that has no
tab_id, like the generic DownloadManager. In this case, we should just
skip the webview connection (as it makes no sense) instead of crashing
(which is the last thing we want to do).
2016-05-05 00:34:16 +02:00
Florian Bruhin
3f66ea1a10
Stabilize buffer test, attempt 2
...
"Current tab changed" actually waited for an unrelated earlier event.
2016-05-04 20:56:54 +02:00
Florian Bruhin
7a82c13b27
bdd: Also log already found log messages
2016-05-04 20:54:34 +02:00
Ryan Roden-Corrent
2536766cac
Run :bind <key> to print the current binding.
...
The <command> arg is now optional. If omitted, :bind prints the current
binding as a message. If --mode is given, the binding for that mode is
printed.
2016-05-03 23:29:34 -04:00
Ryan Roden-Corrent
98508bdd26
Allow flexible whitespace in color strings.
...
Allow a variable amount of whitespace for rgb, rgba, hsv, and hsva
strings in the config.
Previously only 'rgb(0, 0, 0)' was allowed. Now things like
'rgb(0,0,0)' are permitted.
The repeated 3-digit segments of the regexes were separated out to
reduce repetition and line length.
2016-05-03 23:15:39 -04:00
Florian Bruhin
8fb1d568ee
tests: Actually log the colored log
2016-05-01 23:01:22 +02:00
Florian Bruhin
43908dba20
Use colored logging for end-to-end tests
2016-05-01 22:45:21 +02:00
Florian Bruhin
4e333d61cd
Clean up failed userscripts correctly
2016-05-01 22:13:52 +02:00
Florian Bruhin
e3f1949f57
bdd: Fix parsing of logged python warnings
2016-05-01 22:13:31 +02:00
Florian Bruhin
7b575460d5
Fix URL for :quickmark-save test
...
We never noticed this because CherryPy handled this incorrectly in
versions < 5.3.0
2016-04-30 19:08:36 +02:00
Florian Bruhin
2b890901ae
Unskip :stop test on OS X
...
CherryPy now ignores EPROTOTYPE on OS X with 5.3.0, so we can safely
reenable the test.
2016-04-30 18:43:31 +02:00
Florian Bruhin
48c7eee6f6
Release v0.6.2
2016-04-30 18:16:43 +02:00
Florian Bruhin
43d898aa63
Fix log tests
2016-04-30 17:45:45 +02:00
Florian Bruhin
89caf3f497
Add a test for #1464
2016-04-30 14:29:55 +02:00
Florian Bruhin
580f3ed7dc
Remove added blank line
2016-04-30 14:09:14 +02:00
Florian Bruhin
b5aad7d1b9
Merge branch 'issue-1393' of https://github.com/NoctuaNivalis/qutebrowser into NoctuaNivalis-issue-1393
2016-04-30 14:06:54 +02:00
Felix Van der Jeugt
86d08f741c
shorten page and wait for load finished
2016-04-29 21:56:24 +02:00
Florian Bruhin
2d5ffbfd02
Revert "Handle counts for special keys."
...
This reverts commit c881730fad
.
This is just a temporary solution until we can properly fix this.
See #1464
2016-04-29 14:20:11 +02:00
Florian Bruhin
8b227f4ba4
Merge branch 'special_key_count' of https://github.com/rcorre/qutebrowser into rcorre-special_key_count
2016-04-28 22:22:23 +02:00
Florian Bruhin
076b486368
Merge branch 'issue-1412' of https://github.com/Kingdread/qutebrowser into Kingdread-issue-1412
2016-04-27 21:19:04 +02:00
Florian Bruhin
ebfcce172b
Stabilize :buffer tests
2016-04-27 21:08:16 +02:00
Florian Bruhin
2a343cb3a1
Various code style improvements
2016-04-27 20:25:27 +02:00
Daniel Schadt
e8aa242d10
tests: fix invocation test for --cachedir
...
--cachedir="" doesn't work because the quotes are not processed (as they
would be by the shell) and the cachedir is set to ./"" (that is a
directory with two double quotes as name). The correct start parameter
is thus --cachedir=, which correctly fails when the fix is reverted.
2016-04-27 13:02:18 +02:00
Daniel Schadt
951cab237f
tests: factor out common code in test_invocations
2016-04-27 00:04:03 +02:00
Daniel Schadt
758fb94414
tests: add test for DiskCache with cache_dir=None
2016-04-27 00:04:02 +02:00
Daniel Schadt
c0b372591a
tests: add tests for --cachedir=""
2016-04-26 23:26:35 +02:00
Florian Bruhin
7c3361d8da
Stabilize :download-delete test
2016-04-26 22:56:06 +02:00
Felix Van der Jeugt
b7ba3cd53e
fix flake and pep remarks
2016-04-26 22:52:29 +02:00
Felix Van der Jeugt
2d71c541c6
allow swapping dict at runtime
2016-04-26 22:52:29 +02:00
Felix Van der Jeugt
ae72841856
read the wait_for code
2016-04-26 22:52:29 +02:00
Felix Van der Jeugt
9633e79d87
why don't I even know my own options
2016-04-26 22:52:29 +02:00
Felix Van der Jeugt
7d9d4937aa
initial testing - local tox does not work yet
2016-04-26 22:52:29 +02:00
Florian Bruhin
32d64b1a9a
Merge branch 'undo_crash' of https://github.com/rcorre/qutebrowser into rcorre-undo_crash
2016-04-25 19:19:08 +02:00
Florian Bruhin
d6c72c5821
Merge branch 'develop' of https://github.com/kanikaa1234/qutebrowser into kanikaa1234-develop
2016-04-25 19:03:20 +02:00
Florian Bruhin
6349c00c72
Fix crash with :tab-{prev,next,focus} with 0 tabs
...
When using :tab-prev/:tab-next (or :tab-focus which uses :tab-next
internally) immediately after the last tab, those functions could be
called with 0 tabs open, which caused a ZeroDivisionError when trying to
do % 0.
Fixes #1448 .
2016-04-25 18:55:15 +02:00
Florian Bruhin
ef91fa3821
Merge branch 'marks' of https://github.com/rcorre/qutebrowser into rcorre-marks
2016-04-21 20:05:41 +02:00
Florian Bruhin
46a525d0d7
bdd: Improve test IDs for :buffer tests
2016-04-21 19:47:26 +02:00
Florian Bruhin
10fe9cf32d
Stabilize test_buffer_two_window_index_present
...
Fixes #1440
I'm not sure if this was the case, but probably it was.
2016-04-21 19:34:39 +02:00
Ryan Roden-Corrent
399cddf7ac
Actually test double-undo.
2016-04-21 08:04:20 -04:00
Ryan Roden-Corrent
ccd04ca548
Don't crash when undoing twice on default page.
...
Avoid a crash when undoing twice on the default page with last-close set to
default-page.
This was caused by logic to reuse the current tab if it is on the default page
and has no history. The fix is using openurl rather than removeTab/tabopen.
2016-04-21 08:04:20 -04:00
Ryan Roden-Corrent
600b5082a9
Touch up tests and add pyqtSlot for marks.
...
Small code review changes.
2016-04-20 21:53:12 -04:00
Florian Bruhin
a55952375b
bdd: Improve output when comparing sessions
...
See #1440 .
2016-04-21 00:15:37 +02:00
Florian Bruhin
e53c136342
tests: Refactor partial_compare
...
Functions now return a PartialCompareOutcome to attach an error message instead
of a bool, and the main function got rewritten based on a handler dict.
2016-04-21 00:14:13 +02:00
Florian Bruhin
cd128bec8e
bdd: __tracbackhide__ in QuteProcess._wait_for_*
...
This should improve the output we got here:
https://ci.appveyor.com/project/The-Compiler/qutebrowser/build/master-2404/job/gr7m54km6h6nul04
2016-04-20 22:39:52 +02:00
Florian Bruhin
e18b056877
Merge branch 'pretty_url' of https://github.com/forkbong/qutebrowser into forkbong-pretty_url
2016-04-20 22:15:54 +02:00
Florian Bruhin
6a6285495a
Merge branch 'pretty_url_2' of https://github.com/forkbong/qutebrowser into forkbong-pretty_url_2
2016-04-20 20:56:24 +02:00
Panagiotis Ktistakis
8550fb3401
Add tests for {url:pretty} variable
2016-04-20 17:58:14 +03:00
Philipp Hansch
dfc1e5703a
Cleanup unused files
2016-04-20 16:23:18 +02:00
Philipp Hansch
376c5c458e
Convert insert mode tests to non-bdd tests
2016-04-20 16:19:47 +02:00
Philipp Hansch
ff13921aad
Add tests for auto-[leave-]insert-mode
2016-04-20 12:50:33 +02:00
Philipp Hansch
601687ba61
Add insert mode feature tests
...
Issue-Link: #999
2016-04-20 11:04:53 +02:00
Florian Bruhin
22582773b1
Fix lint
2016-04-20 09:00:01 +02:00
Florian Bruhin
bc815505f1
bdd: Output fewer = chars for summary headers
...
Otherwise we have line breaks on Travis CI
2016-04-20 07:55:59 +02:00
Florian Bruhin
4520261884
bdd: Make TestProcess.log_summary public
...
We want to use it from the BDD conftest.py
2016-04-20 07:55:23 +02:00
Florian Bruhin
6cf4cebfd4
bdd: Show messages we're waiting for in the log
2016-04-20 07:49:08 +02:00
Florian Bruhin
a99cb5f6b2
bdd: Improve wait_for_load_finished output
2016-04-20 07:38:32 +02:00
Florian Bruhin
5e91ad6c42
bdd: Shorten InvalidLine exception output
2016-04-20 07:38:32 +02:00
Florian Bruhin
266bc6e8d8
bdd: Don't shorten log if an exception happened
2016-04-20 07:38:32 +02:00
Florian Bruhin
1579f27564
bdd: Add sections to log
...
See #1418
2016-04-20 07:38:12 +02:00
Ryan Roden-Corrent
c881730fad
Handle counts for special keys.
...
Now 3<ctrl-o> will execute whatever <ctrl-o> is mapped to with count=3.
2016-04-19 23:39:02 -04:00
Ryan Roden-Corrent
0755e163bb
Only set the ' mark on normal/current hinting.
...
Don't set ' for downloading, hovering, or opening a link in a tab.
2016-04-19 21:18:20 -04:00
kanikaa1234
fae005ab7f
:navigate: command and test feature
2016-04-19 20:30:20 +05:30
Florian Bruhin
6aaea2aa31
Fix HeaderDict with an empty value
2016-04-19 09:43:54 +02:00
Florian Bruhin
e860d8cfea
Add a custom-headers setting
...
Supersedes #1132
Closes #1020 .
2016-04-19 06:35:32 +02:00
Florian Bruhin
c5999443a1
Implement a HeaderDict config type
...
Supersedes #1132 .
Fixes #1022 .
2016-04-19 06:35:20 +02:00
Panagiotis Ktistakis
bd6783c7e6
Add --pretty flag to :yank
...
With --pretty, the URL is yanked in a "pretty form", with most
percent-encoded characters decoded. Partially fixes #1372 .
2016-04-18 23:10:53 +03:00
Ryan Roden-Corrent
2b68aaa311
Make set_mark searching tests less flaky.
...
Replace all the html numbers with a few widely spaced divs to guarantee the
search will move the viewport on almost and reasonable screen size.
2016-04-18 12:30:16 -04:00
Ryan Roden-Corrent
a924144d9a
Set ' mark after searching.
...
Allow jumping back to the previous position after a search jumps you around.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
4b00a17d71
Fix MarkKeyParser crash when changing keyconfig.
...
Ensure MarkKeyParser implements on_keyconfig_changed, so it doesn't fail when
rebinding a key. It doesn't have keybindings, so the implementation is just
`pass`.
This also fixes a few flake8 style errors.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
be6308534f
Store both x and y position for marks.
...
Previously only stored/used y.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
e684cfa03f
Trivial fixes for marks based on code review.
...
- Fix a docstring copy-paste
- Add own name/copyright date to new file
- Simplify a bdd expression (no need for regex)
- Scroll to a pixel position in a single operation
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
540f4af225
Set the ' mark after following a link.
...
This moves mark storage from CommandDispatcher to TabbedBrowser, so it can also
be accessed by the HintManager.
2016-04-17 21:04:08 -04:00
Ryan Roden-Corrent
dc246772e7
Add integration tests for set-mark and jump-mark.
2016-04-17 21:04:08 -04:00
Jakub Klinkovský
0eab422540
tests: replace paths to data/hints/link.html
...
an adjustment due to 35ed70cfe0
2016-04-15 23:19:08 +02:00
Jakub Klinkovský
3265601eab
Merge remote-tracking branch 'upstream/master' into hints_clicking
...
* upstream/master: (327 commits)
Remove unused import
tox: Update Werkzeug to 0.11.8
Regenerate authors
Use __file__ instead of sys.argv[0]
Regenerate authors
Make update_3rdparty.py install correctly when run from any directory
Open command line urls explicitly.
tox: Update Werkzeug to 0.11.6
Move qutebrowser.rcc to misc/
Regenerate resources
Fix CHANGELOG/link in README
New qutebrowser logo!
www: Add releases link
Release v0.6.1
release checklist: Clarify how to build on Windows
Make sure the cheatsheet PNG is included in sdist
Fix cheatsheet link URL in quickstart
Mark segfault on exit in test_smoke as xfail
Add a xfail test for #797
Add missing file
...
Conflicts:
tests/integration/features/hints.feature
2016-04-15 22:37:47 +02:00
Florian Bruhin
c690e652dc
Release v0.6.1
2016-04-10 21:25:32 +02:00
Florian Bruhin
0776aaf32c
Mark segfault on exit in test_smoke as xfail
...
See #1387 .
I know this is... less than optimal, but I can't do anything :-/
2016-04-10 20:52:07 +02:00
Florian Bruhin
6e7aefca00
Add a xfail test for #797
2016-04-10 20:30:26 +02:00
Florian Bruhin
3409559958
Add missing file
2016-04-10 20:28:10 +02:00
Florian Bruhin
6989d4d210
Fix downloading of non-ascii files with LC_ALL=C
...
Fixes #908 .
2016-04-10 20:16:40 +02:00
Florian Bruhin
98f0938d35
Rename test_cmdline_args to test_invocations
2016-04-10 19:56:44 +02:00
Florian Bruhin
1954ebd63c
Fix test_last_window_session_none
2016-04-10 18:22:58 +02:00
Johannes Martinsson
570d8b4abe
Make tab-focus count from end with negative index
...
This makes it possible to jump to the very last tab, as opposed to the
last focused tab, by using -1 as the index. Generally negative indexes
are counted from the end.
Solves issue #1166
2016-04-09 03:40:36 +02:00
Florian Bruhin
642dc46ba9
flake8: Add hacking
2016-04-08 07:35:53 +02:00
Florian Bruhin
00873fd000
Fix Proxy configtype test
2016-04-07 21:42:26 +02:00
Florian Bruhin
9ea7716b06
Stop supporting running tests without Xvfb/DISPLAY
...
This always caused problems and unneeded complexity in the past, and it
also increases Travis CI runtime.
We now require either a DISPLAY during tests or Xvfb being installed.
2016-04-06 08:27:43 +02:00
Florian Bruhin
d02d99e53e
bdd: Make quteproc.set_setting work with quotes
...
This hopefully fixes editor BDD tests on Windows as the editor path is
now correctly quoted.
2016-04-06 08:13:43 +02:00
Florian Bruhin
7141941ece
Fix lint
2016-04-06 07:17:13 +02:00
Florian Bruhin
f0b66130d6
Merge branch 'rcorre-edit-url'
2016-04-06 06:52:43 +02:00
Florian Bruhin
86dec02fe8
bdd: Add tests for :edit-url
2016-04-06 06:47:19 +02:00
Florian Bruhin
2f520f3b17
Rename test_editor.py to test_editor_unit.py
2016-04-05 19:49:01 +02:00
Florian Bruhin
537d017ec2
@Kingdread is faster than AppVeyor
2016-04-05 14:11:51 +02:00
Florian Bruhin
0abd16f6e5
tests: Use repr to wait for download question
...
The tests failed on Windows because a double-slash was printed in the
logs, but the tests expected a single one.
2016-04-05 14:09:25 +02:00
Florian Bruhin
860853f66f
Fix lint
2016-04-05 12:40:46 +02:00
Florian Bruhin
ebee06a9c4
bdd: Add tests for download-path-suggestion
2016-04-05 11:43:35 +02:00
Florian Bruhin
c67edcf811
tests: Add v0.6.0 config to test_old_config
2016-04-04 18:16:31 +02:00
Florian Bruhin
19edea7343
Rename unit/misc/test_sessions.py to *_unit.py
...
Otherwise we get:
import file mismatch:
imported module 'test_sessions' has this __file__ attribute:
/home/florian/proj/qutebrowser/git/tests/integration/features/test_sessions.py
which is not the same as the test file we want to collect:
/home/florian/proj/qutebrowser/git/tests/unit/misc/test_sessions.py
HINT: remove __pycache__ / .pyc files and/or use a unique basename for your test file modules
2016-04-01 07:52:54 +02:00
Florian Bruhin
6631c6456c
Merge branch 'session-tests'
2016-04-01 06:15:52 +02:00
Florian Bruhin
aad2407de1
Merge branch 'force-current-tab' of https://github.com/paretje/qutebrowser into paretje-force-current-tab
2016-04-01 06:13:08 +02:00
Kevin Velghe
0652637fbe
Refactor unit tests for remove_blank_target
2016-04-01 01:32:27 +02:00
Florian Bruhin
d30093b877
Skip "Focusing download widget via Tab" on old Qt
...
Qt < 5.3.1 (used on Travis with Ubuntu Trusty) has a bug with its
javascript prompt implementation, so we can't run that test there.
2016-03-31 21:12:13 +02:00
Florian Bruhin
89742beb4e
pylint: useless-suppression in test_qt_javascript
...
When QtWebEngine is available, the suppression is useless.
2016-03-31 20:18:26 +02:00
Florian Bruhin
27b31b7ded
Avoid DownloadView being focused when pressing tab
...
The previous fix didn't work in situations where the web view was
actually focused, but had no focused element (like about:blank).
The new fix always works, and even is a lot simpler!
Fixes #504 .
2016-03-31 19:45:36 +02:00
Florian Bruhin
123fd18af5
Fix crash when removing download in closed window
...
When a download is finished with `removed-finished-download` set to a
delay, it's removed via a singleshot QTimer.
However, when the window was closed in the meantime, the slot still was
executed by Qt, even though the DownloadManager was already deleted.
Fixes #1242
2016-03-31 19:09:43 +02:00
Kevin Velghe
e90ad3d9c0
Complete coverage for webelem
2016-03-31 10:25:44 +02:00
Kevin Velghe
ef6ffd6a3a
Add link_span.html
2016-03-31 09:36:13 +02:00
Jimmy
97ab6db655
Adds tests for buffer command.
...
The buffer_troubling_args tests may look a little un-intuitive but that is
because they are testing the edge cases for the current behaviour. If these
edge cases are encountered during normal usage you are doing something wrong.
2016-03-31 14:00:36 +13:00
Kevin Velghe
0432ba68c6
Add hints integration test
2016-03-30 23:53:18 +02:00
Kevin Velghe
00f1e699d4
Add extra test to test_remove_blank_target
2016-03-30 23:46:02 +02:00
Florian Bruhin
a6a2210ce8
Add tests for #879
2016-03-30 22:16:36 +02:00
Kevin Velghe
dd4710d596
Fix test_remove_blank_target
2016-03-30 19:54:42 +02:00
Kevin Velghe
f4f926cdca
Add integration tests for current target hints
2016-03-30 19:49:25 +02:00
Kevin Velghe
a432102be0
Add webelem tests for remove_blank_target
2016-03-30 19:08:37 +02:00
Florian Bruhin
5a5e8167dd
Fix lint
2016-03-29 23:20:39 +02:00
Florian Bruhin
6c7e2492e9
Merge branch 'dirbrowser-issue-1334' of https://github.com/Kingdread/qutebrowser into Kingdread-dirbrowser-issue-1334
2016-03-29 22:38:04 +02:00
Florian Bruhin
fc7e75c355
Fix lint
2016-03-29 22:30:26 +02:00
Florian Bruhin
4067d38cb0
Add some tests for QtWebKit/Engine JS capabilities
2016-03-29 22:08:49 +02:00
Florian Bruhin
fee3b9a02b
Merge branch 'bdd_test_spawn_command' of https://github.com/phansch/qutebrowser into phansch-bdd_test_spawn_command
2016-03-29 21:12:29 +02:00
Florian Bruhin
de5ecbf4e7
Fix lint
2016-03-29 21:10:29 +02:00
Daniel Schadt
bd5b1f207d
fix lint
2016-03-29 21:02:54 +02:00
Daniel Schadt
3007fbf5c2
tests: add tests for quteproc.click_element
2016-03-29 20:52:23 +02:00
Daniel Schadt
f82d0f0c94
quteprocess: properly escape xpath expression
...
Since XPath doesn't have a way to escape quotes (or any other
character), we have to use a workaround by using concat() and switching
between quoting styles.
2016-03-29 20:34:40 +02:00
Philipp Hansch
e0e8bc805b
Remove unneeded argument
...
Instead, figure out the data directory from the helpers directory.
2016-03-29 19:52:46 +02:00
Philipp Hansch
4a1ba45efa
Merge remote-tracking branch 'upstream/master' into bdd_test_spawn_command
2016-03-29 19:24:43 +02:00
Florian Bruhin
f43cbed72f
tests: Inherit HTTPPostStub from QObject
...
This way we can test the actual signals instead of calling
on_client_success by hand.
2016-03-29 19:22:28 +02:00
Florian Bruhin
25555682dc
Merge branch 'master' of https://github.com/arsana7/qutebrowser into arsana7-master
2016-03-29 18:59:06 +02:00
Philipp Hansch
5ae0b0cf87
Ignore test on Windows
...
The userscript is a bash script and there is no bash on windows.
One solution could be to use a python userscript, but there may be
other issues (file associations), too.
2016-03-29 14:17:47 +02:00
Daniel Schadt
b6c5ff25fd
tests: add click_element to quteprocess
2016-03-29 13:32:35 +02:00
Philipp Hansch
8a619ea84c
Prevent slashes from being stripped on Windows
2016-03-29 13:25:04 +02:00
Daniel Schadt
f085eb6eca
tests/dirbrowser: move parse out of DirLayout
2016-03-29 12:43:50 +02:00
Daniel Schadt
2db5b95552
tests: use "if not parent_elem"
...
Also add a new test for browsing the root directory
2016-03-29 12:36:43 +02:00
Philipp Hansch
b1ecdf2924
Try to fix path issue on windows
2016-03-29 12:11:01 +02:00
Florian Bruhin
f15fb16ad4
Fix small nitpick
2016-03-29 07:09:17 +02:00
Florian Bruhin
606471c4b6
Merge branch 'test_statusbar_url' of https://github.com/craftyguy/qutebrowser into craftyguy-test_statusbar_url
2016-03-29 07:07:45 +02:00
Philipp Hansch
c016c77da4
Try to fix Windows path issue with new custom step
...
On windows, using '/' in pathnames won't work, so it's impossible to use
to describe a path in a feature spec. The solution is to move the path
logic out of the feature spec and hand it over to `os.path.join` in a
new custom step for userscripts.
2016-03-29 01:37:40 +02:00
Clayton Craft
c811db5424
remove unused import
2016-03-28 15:31:28 -07:00
Clayton Craft
e0c0613db6
Added new test for simulating loading page and hover/unhover URL
2016-03-28 15:12:16 -07:00
Philipp Hansch
e9ae2156d3
Comply with flake8
2016-03-29 00:08:14 +02:00
Philipp Hansch
449adc2dc1
Try not to confuse syntax highlighting with quotes
2016-03-28 23:53:26 +02:00
Philipp Hansch
5811a25299
Add a datapath replacement for spawning userscripts
...
This adds a `(datapath)` replacement for feature tests.
`(datapath)` will expand to the absolute path to the integration data
directory.
2016-03-28 23:48:37 +02:00
Daniel Schadt
6a96e1d6d8
quteprocess: remove duplicate code
2016-03-28 23:10:20 +02:00
Daniel Schadt
c0b40aefdd
tests/dirbrowser: normalize paths before comparing
...
This avoids errors because some libraries use '/' even on windows, while
others use '\' on windows.
2016-03-28 23:10:20 +02:00
Daniel Schadt
f6e8815871
tests: add integration tests for dirbrowser
2016-03-28 23:10:20 +02:00
Daniel Schadt
5e73a2ea37
dirbrowser: move parent dir logic to own function
2016-03-28 23:10:20 +02:00
Daniel Schadt
e97b10517f
tests: use file_url for dirbrowser tests
...
Otherwise the tests will fail on windows.
2016-03-28 23:10:20 +02:00
Daniel Schadt
700756aa16
tests: add more cases for dirbrowser.is_root
...
The trailing slash might have an effect on the function result, so we
should have cases with/without the slash.
2016-03-28 23:08:54 +02:00
Clayton Craft
32304f36dd
fix pylint failure
2016-03-25 16:35:49 -07:00
Florian Bruhin
387e35d3e5
Fix lint
2016-03-26 00:24:54 +01:00
Florian Bruhin
9edc5a665e
Handle jinja's UndefinedError in jinja.render
...
We can get UndefinedError when a new function got added to the jinja
env (and gets called from a template) and the user did update the
on-disk templates but not restart qutebrowser yet.
In this case, let's show a special error page to the user and tell them
to do :report in the unlikely case it's actually a bug.
Fixes #1362 .
See #1360 .
2016-03-26 00:00:06 +01:00
Clayton Craft
4778ff6f9c
Cleaned up url test and improved coveraged based on feedback
2016-03-25 15:56:39 -07:00
Philipp Hansch
0083538491
Add basic test for spawning userscripts
2016-03-25 18:21:38 +01:00
Philipp Hansch
69da5d7545
Add BDD tests for spawn command
...
Issue-Link: https://github.com/The-Compiler/qutebrowser/issues/999
2016-03-25 18:19:35 +01:00
Florian Bruhin
86b12a302e
Add a jinja.render helper
...
This simplifies some code and will make #1362 possible.
2016-03-25 14:29:30 +01:00
Florian Bruhin
74ee0d88e3
Merge branch 'system-wide-data-path' of https://github.com/craftyguy/qutebrowser into craftyguy-system-wide-data-path
2016-03-25 11:04:10 +01:00
Clayton Craft
ff4e17190f
Allow searching system-wide data path on Linux for userscripts
2016-03-24 13:22:00 -07:00
Clayton Craft
a78644a199
Implement statusbar.url test
2016-03-24 12:57:14 -07:00
Philipp Hansch
a0e32753a5
Forgot a possible race condition
2016-03-24 12:20:08 +01:00
Philipp Hansch
624aa9b41d
Try to fix possible race conditions
2016-03-24 11:40:10 +01:00
Philipp Hansch
7e55eee1b9
Set background-tabs to false for rest of the tests
...
Because it is set to true in a previous test and it is better to avoid
shared state in tests. Especially, if we want to randomize tests later
on.
2016-03-24 10:20:21 +01:00
Philipp Hansch
38bda67adc
Add background-tabs and new-tab-position tests
...
Using hints to select and open the link.
Not sure if there are better ways.
Issue-Link: https://github.com/The-Compiler/qutebrowser/issues/999
2016-03-24 10:09:19 +01:00
Florian Bruhin
a932183909
Merge branch 'master' of https://github.com/haxwithaxe/qutebrowser into haxwithaxe-master
2016-03-18 06:17:54 +01:00
haxwithaxe
eed13467f3
allow {0} in search engine specification strings to allow multiple instances of the search term in the url
2016-03-17 20:38:05 -04:00
Florian Bruhin
74706abbc1
Fix lint
2016-03-17 22:10:58 +01:00
Florian Bruhin
0830b400fe
Merge branch 'editor_crash_behaviour' of https://github.com/EliteTK/qutebrowser into EliteTK-editor_crash_behaviour
2016-03-17 21:40:17 +01:00
Florian Bruhin
99fadacda6
Merge branch 'multi_url_heuristic' of https://github.com/hcraT/qutebrowser into hcraT-multi_url_heuristic
2016-03-17 21:28:40 +01:00
Jakub Klinkovský
e121bd764f
hints: add another iframe test
2016-03-16 21:47:58 +01:00
Jakub Klinkovský
164df521c1
hints: add verifications for iframe tests
2016-03-16 20:59:46 +01:00
Florian Bruhin
ed3fd71e6f
Force showing of label in test_elided_text
...
It seems the paintEvent of TextBase never got called since we switched to using
fake_statusbar, breaking the 100% coverage check.
2016-03-15 08:29:33 +01:00
Florian Bruhin
569e7b11fb
Make test_elided_text work with non-unicode output
...
When Qt detects it can't output unicode (via the locale?), it elides using
"..." instead of the unicode char "…". Now the test works in both scenarios.
2016-03-15 07:19:43 +01:00
Florian Bruhin
97ddd674dd
Use fake_statusbar for test_elided_text
...
See #1313
2016-03-15 07:14:39 +01:00
Florian Bruhin
41b6f68fd7
bdd: Add some more tests for downloads
2016-03-14 19:06:42 +01:00
Florian Bruhin
06190a0488
bdd: Do better cleanup/separation for downloads
2016-03-14 19:06:16 +01:00
Florian Bruhin
42a4c1ce4c
Also test transform in test_configtypes_hypothesis
...
If validating works, we might as well also check if transforming does too.
2016-03-11 07:26:16 +01:00
Florian Bruhin
0c6d6367de
Force qapp fixture for test_configtypes_hypothesis.
...
The test needs a QApplication
2016-03-11 07:17:11 +01:00
Florian Bruhin
5d87770513
tests: Allow XPASS for test_installed_package
...
We need to use strict=False here as test_installed_package can XPASS when
running frozen tests.
2016-03-02 08:09:04 +01:00
Florian Bruhin
d1ec64cab1
Remove skip marker as it's builtin in pytest now
2016-03-02 07:14:06 +01:00
Tarcisio Fedrizzi
9286fadeee
Adds wait to paste multiline text test
2016-02-29 00:39:37 +01:00
Tarcisio Fedrizzi
a9fdf09a04
Adds test of the heuristic
2016-02-28 23:44:26 +01:00
Tarcisio Fedrizzi
89ac5cba62
Adds test to reach 100% coverage on urlutils
2016-02-28 23:43:38 +01:00
Florian Bruhin
5395e0f6e2
tests: Use a fresh instance as a workaround
...
Waiting seems like a perfect recipe for another flaky test, so let's better be
safe.
2016-02-28 15:26:18 +01:00
Florian Bruhin
c156f53eba
Merge branch 'data-link-fix' of https://github.com/Kingdread/qutebrowser into Kingdread-data-link-fix
2016-02-27 03:01:19 +01:00
Florian Bruhin
48f87d1656
Revert "Use pytest-platform-markers"
...
This reverts commit 2e12fb3c65
.
It seems like it's currently broken...
2016-02-27 02:45:34 +01:00
Florian Bruhin
a4687c6745
Fix lint
2016-02-27 02:41:01 +01:00
Florian Bruhin
83e86706ff
tests: Make check for ddg being loaded less strict
...
Before this change, adding a new logging message involving logging e.g. the
default duckduckgo setting value failed.
Now we basically use a black- instead of a whitelist and only fail if we get a
load status message for duckduckgo.
2016-02-27 02:16:42 +01:00
Florian Bruhin
2e12fb3c65
Use pytest-platform-markers
2016-02-27 00:26:24 +01:00
Jakub Klinkovský
d4ea62a834
hints: add xfailed tests for hinting inside iframes
2016-02-24 23:15:13 +01:00
Jakub Klinkovský
891a31a0ca
hints: move zoom tests to test_hints_html.py
2016-02-23 18:51:32 +01:00
Jakub Klinkovský
35ed70cfe0
hints: split tests into individual HTML files
2016-02-23 18:19:52 +01:00
Jakub Klinkovský
58d2d92d67
Merge remote-tracking branch 'upstream/master' into hints_clicking
...
* upstream/master: (22 commits)
Regenerate authors.
Only run geolocation tests on CI
Switch to flake8-docstrings with pydocstyle
Fix lint
Move pylint plugins to an installed package.
Include pytest-xvfb properly in frozen tests
tests: Handle trailing / in wait_for_load_finished.
Fix lint.
tox: Upgrade hypothesis to 3.0.2.
tests: Add first end-to-end test for hints.
hints: Log the used hint chars
bdd: use quteproc.wait_for_load_finished.
Remove xvfbwrapper from freeze_tests.py.
Regenerate authors.
Combine launch/crash time into one section.
Split long lines.
Switch to pytest-xvfb. Fixes #1309 .
no ellipsis is inserted in big windows
Regenerate authors.
fixes #1308
...
2016-02-23 17:40:02 +01:00
Daniel Schadt
a382b366bc
tests: increase wait time
...
Otherwise the test might still fail on some systems
2016-02-22 21:46:54 +01:00
avk
c9bb6d0111
tests for browser.network.pastebin - code refactor
2016-02-22 20:46:22 +01:00
Daniel Schadt
a84c8ac247
tests: add workaround for QPainter bug
...
As suggested in the github discussion.
2016-02-22 17:39:34 +01:00
avk
90c8078225
More tests for browser.network.pastebin
2016-02-22 16:09:57 +01:00
avk
6826a97910
Tests for browser.network.pastebin
2016-02-22 15:10:39 +01:00
Florian Bruhin
3ff419f685
Merge branch 'fix/ellipses-on-fullscreen' of https://github.com/NoctuaNivalis/qutebrowser into NoctuaNivalis-fix/ellipses-on-fullscreen
2016-02-22 11:50:26 +01:00
Florian Bruhin
f64916b516
Only run geolocation tests on CI
...
Trying to get the device location while running the tests can trigger all kind
of funny effects.
Since we can't easily mock the GPS responses, we only run those on the CI where
we at least have some predictable setup.
Fixes #1297 .
2016-02-21 17:24:33 +01:00
Jakub Klinkovský
52a9405f74
hints: fix descriptions of zoom tests
2016-02-21 12:53:03 +01:00
Florian Bruhin
b201b65669
tests: Handle trailing / in wait_for_load_finished.
...
We actually already added that in 16ec035418
, but
in 9a02dc174d
we accidentally dropped it again.
2016-02-19 06:42:23 +01:00
Florian Bruhin
6a077f5d5a
Fix lint.
2016-02-18 21:38:23 +01:00
Florian Bruhin
36b0e304fc
tests: Add first end-to-end test for hints.
...
This is based on HTML files with a global YAML comment, currently with "target"
as the only allowed key.
The tests then do this:
- Open a HTML file in data/hints/html
- Start hinting
- Make sure only one hint is visible
- Follow it, and make sure the page mentioned in "target:" is reached
Some ideas for the future:
- A "scroll" key, to scroll before hinting
- A "zoom" key, to zoom
- Multiple hints via a list
- Checking position of hints?
- A mode to manually check the pages (to check hint positions)
2016-02-18 20:46:15 +01:00
Florian Bruhin
9a02dc174d
bdd: use quteproc.wait_for_load_finished.
...
Why duplicate that logic?
2016-02-18 20:46:15 +01:00
Daniel Schadt
007425cf16
downloads: fix filename for data: links
...
Issue #1214
Now uses a sensible filename for data: links instead of the whole base64
content. For PDF.js, it even uses the correct pdf filename.
TODO: Produces "QPainter:🔚 Painter ended with 2 saved states" while
running the tests here (Arch Linux):
CPython: 3.5.1
Qt: 5.5.1, runtime: 5.5.1
PyQt: 5.5.1
2016-02-18 16:17:35 +01:00
Florian Bruhin
5c617b861c
Switch to pytest-xvfb. Fixes #1309 .
2016-02-16 20:36:23 +01:00
Jakub Klinkovský
97d2038528
hints: make sure that all hints stay visible in tests
2016-02-16 00:05:58 +01:00
Jakub Klinkovský
9799c30c2b
hints: add precision tests for different zoom levels
2016-02-15 23:31:49 +01:00
Felix Van der Jeugt
c52e93e296
no ellipsis is inserted in big windows
2016-02-15 22:52:28 +01:00
Florian Bruhin
aa579d76c9
Merge branch 'fix/#1308' of https://github.com/NoctuaNivalis/qutebrowser into NoctuaNivalis-fix/#1308
2016-02-15 22:08:33 +01:00
Felix Van der Jeugt
60c2b9c0b2
fixes #1308
2016-02-15 21:59:09 +01:00
Jakub Klinkovský
239b7497e9
hints: simplify tests and make them more reliable
2016-02-15 20:41:54 +01:00
Jakub Klinkovský
748ec043fb
hints: add tests for links known to cause troubles
2016-02-15 19:02:29 +01:00
Florian Bruhin
74e168c339
Update Pygments test file.
2016-02-15 07:47:29 +01:00
Florian Bruhin
02f367a308
Add basic profiling capability for quteproc tests.
...
When --qute-profile-subprocs is given, we write a profile file for each
qutebrowser invocation and also create prof/combined.pstats afterwards.
2016-02-11 08:02:44 +01:00
Florian Bruhin
5311576c34
Check pep257 via flake8.
...
We'll still keep the pydocstyle environment though until flake8-pep257 adds
support for that:
https://github.com/Robpol86/flake8-pep257/issues/6
2016-02-10 19:18:47 +01:00
Florian Bruhin
7f791dfcb8
Remove now obsolete test.
2016-02-10 07:06:34 +01:00
Florian Bruhin
b6f1dd963d
Handle Shift-Insert correctly in prompt mode.
...
Fixes #1299 .
2016-02-10 06:40:54 +01:00
Florian Bruhin
5ae677376b
Rerun TestPyQIODevice.test_qprocess if needed.
...
This adds a new pytest-rerunfailures dependency. For some reason, that test
sometimes fails with an empty string read, and I can't tell why.
2016-02-08 06:54:47 +01:00
Daniel Schadt
d02ec62e33
tests: fix tests for test_version
...
Broken since we changed pdfjs.PDFJSNotFound to have a parameter, which
was not given here.
2016-02-05 15:16:23 +01:00
Daniel Schadt
df8f87f8b6
tests: add tests for qutescheme
2016-02-05 15:14:23 +01:00
Florian Bruhin
83dc390808
tests: Move fixtures into a separate file.
2016-02-04 07:27:23 +01:00
Florian Bruhin
eb692ba7f6
Fix lint.
2016-02-04 07:13:27 +01:00
Florian Bruhin
774bcbf6b3
tests: Don't fail on teardown too if test failed.
...
When a end-to-end test failed which would've marked an error message as
expected later in the test, seeing the teardown message about an unexpected
error being logged is really confusing.
2016-02-04 06:43:14 +01:00
Florian Bruhin
43b6f18864
Whoops, don't use repr(json.dumps(...))
2016-02-03 21:28:20 +01:00
Florian Bruhin
e5e1a0d95c
Reject hints -> chars containing duplicate chars
...
Fixes #1286 .
2016-02-03 21:05:35 +01:00
Florian Bruhin
0b491f6caf
Use json.dumps for logged fake clipboard.
...
For some reason, when comparing the repr in the two processes, we get different
results on OS X and Windows:
- expected: "fünf"
- "f\xfcnf" coming back from the subprocess on OS X
- "fnf" on Windows
Instead we're comparing the json dump now, which should be more predictable.
2016-02-03 20:54:35 +01:00
Florian Bruhin
79f83a033d
Add a fake clipboard for tests
...
There are a lot of problems and flakiness with using a real clipboard.
Instead we now have a :debug-set-fake-clipboard command to set a text, and use
logging when getting the contents.
Fixes #1285 .
2016-02-03 20:27:11 +01:00
Florian Bruhin
921e8b50b7
Fix lint.
2016-02-03 08:16:59 +01:00
Florian Bruhin
3292c05340
tests: Display some more qutebrowser logs w/o -v.
...
50 lines of context is almost useless, e.g. when an exception occurs we don't
even see the traceback.
2016-02-03 07:55:10 +01:00
Florian Bruhin
6008adcb9f
bdd: xfail broken yankpaste tests for now.
...
Using the clipboard seems to be a good recipe for a lot of weird pain.
Until we avoid it altogether (see #1285 ) we xfail those problematic tests.
2016-02-03 07:49:45 +01:00
Florian Bruhin
302745e0fe
tests: Also poll clipboard after setting it.
2016-02-03 07:44:41 +01:00
Florian Bruhin
a90618128d
tests: Empty clipboard after testing if it works.
...
Otherwise, if a test fails to actually put something into the clipboard, we end
up pasting "Does this work?" which could e.g. trigger a search.
When it's cleared, we at least get some "clipboard is empty" error instead.
2016-02-03 06:55:21 +01:00
Florian Bruhin
af28996f82
tests: Fail if duckduckgo gets loaded accidentally
...
In the long run, we should detect any accidental external accesses using
mitmproxy, as per #1282 . In the meantime, we try to detect duckduckgo requests
being logged and fail the tests if that happens.
However, a duckduckgo URL is logged in fuzzy_url during startup/config init,
which is why we ignore it there.
2016-02-03 06:50:48 +01:00
Daniel Schadt
1e52f459c9
mhtml: new complex test case
...
The-Compiler wants a more beautiful test case since the old one was
pretty weird and took lots of explaining at pytest demos, so I made a
new one. This one is a bit nicer on the eye and - to say it with
The-Compiler's words - has no "weird pixelated globe with the
geocities-like background".
To compensate for the globe I've put in some trivia facts so that - if
you are one of the people that like to stare at test pages - you can
always learn something.
2016-02-02 22:23:40 +01:00
Florian Bruhin
67efd1c5e0
Fix lint.
2016-02-02 19:23:24 +01:00
Florian Bruhin
cf0034d42c
Set __tracebackhide__ in quteproc.after_test
2016-02-02 19:16:45 +01:00
Florian Bruhin
65a4c71488
Merge branch 'master' of https://github.com/NoctuaNivalis/qutebrowser into NoctuaNivalis-master
2016-02-02 18:58:16 +01:00
Florian Bruhin
37bb26bdd5
Add a test in test_editor.py.
2016-02-02 06:53:12 +01:00
Florian Bruhin
ad290e8702
Merge branch 'relax-editor-templating' of https://github.com/Olical/qutebrowser into Olical-relax-editor-templating
2016-02-02 06:49:57 +01:00
Florian Bruhin
312daca2b0
fuzzy_url: Raise InvalidUrlError on empty URLs.
...
Before we raised QtValueError (via qtutils.ensure_valid), but maybe there are
more callers out there which call fuzzy_url with an empty input - and it makes
more sense to raise InvalidUrlError which gets displayed to the user than
raising QtValueError which is more like an assertion.
2016-02-02 06:38:48 +01:00
Florian Bruhin
14042403f6
Fix pasting of empty URLs.
2016-02-02 06:37:49 +01:00
Oliver Caldwell
a617bc3ef4
Add missing commas
...
I haven't written Python in quite a long time :|
2016-02-01 21:41:14 +00:00
Oliver Caldwell
5474f902dd
Add more tests for new editor config
2016-02-01 21:36:24 +00:00
Oliver Caldwell
a14f8a201e
Merge remote-tracking branch 'TheCompiler/master' into relax-editor-templating
2016-02-01 21:19:50 +00:00
Daniel Schadt
449a54c7d0
pdfjs: add file path to version information
...
Shows "bundled" if the bundled version is used.
2016-02-01 17:28:18 +01:00
Oliver Caldwell
54ff2aa46c
Merge remote-tracking branch 'TheCompiler/master' into relax-editor-templating
2016-01-31 22:43:58 +00:00
Oliver Caldwell
a9a42e0a99
Removed invalid placeholder test
2016-01-31 22:36:58 +00:00
Oliver Caldwell
84c44f3395
Remove invalid test parameter
2016-01-31 22:23:35 +00:00
Florian Bruhin
d50e1be566
Add some more :paste-primary tests.
2016-01-31 22:08:46 +01:00
Florian Bruhin
af5d199e8f
bdd: Simplify :paste-primary tests.
2016-01-31 20:56:37 +01:00
Florian Bruhin
44625b254c
Merge branch 'shift_ins' of https://github.com/lahwaacz/qutebrowser into lahwaacz-shift_ins
2016-01-31 19:46:41 +01:00
Jakub Klinkovský
5ec224d1f9
Simplified test for paste-primary command
...
We don't need to move around for this test...
2016-01-30 14:03:54 +01:00
Jakub Klinkovský
b358566156
Added tests for paste-primary command
2016-01-30 13:57:26 +01:00
Florian Bruhin
85adf7593d
Fix crash when downloading URL without path infos.
...
Fixes #1243 .
2016-01-26 22:39:10 +01:00
Florian Bruhin
ea1627c1e6
Cancel permission prompt when tab is closed.
...
Fixes #1250 .
2016-01-26 19:47:31 +01:00
Florian Bruhin
4d9ea06768
tests: Make test IDs predictable.
...
This means we could use xdist in the future.
2016-01-25 22:15:31 +01:00
Florian Bruhin
aede904b3a
bdd: Stabilize "Cloning to background tab" test.
...
I think this didn't actually wait until hello.txt was loaded because some logs
were parsed from the previous test:
http://www.qutebrowser.org/testresults/osx/1294.html
2016-01-24 19:17:39 +01:00
Florian Bruhin
be2c0e30b6
bdd: Stabilize "Closing a JS window twice" test.
...
After pressing the button to open a window, we have to wait until it's loaded
before continuing, otherwise the test is flaky:
http://www.qutebrowser.org/testresults/osx/1295.html
We can't simply wait with "wait until about:blank is loaded" as that page is
already loaded earlier.
2016-01-24 18:47:26 +01:00
Florian Bruhin
7dca8d7329
Fix lint.
2016-01-24 17:30:59 +01:00
Florian Bruhin
86f03c7d81
Merge branch 'master' of https://github.com/mikeri/qutebrowser into mikeri-master
2016-01-24 17:01:35 +01:00
Corentin Julé
6fd8dc4e57
Correct test_config_change
2016-01-23 16:34:05 +01:00
Corentin Julé
47261dbd30
Code cleanup / Good practices
2016-01-23 16:15:19 +01:00
Florian Bruhin
58fb2826ee
flake8: Add flake8-putty plugin.
...
Apply a bit of putty to flake8.
https://pypi.python.org/pypi/flake8-putty/
2016-01-22 17:33:58 +01:00
Florian Bruhin
526441bcae
Fix new flake8 lint.
...
For some reason these issues weren't shown with pytest-pep8/flakes.
2016-01-22 17:33:58 +01:00
Michael Ilsaas
4ad2d63c8a
Shortened urlincdec tests to one and some styling
2016-01-21 18:37:46 +01:00
Michael Ilsaas
1ecccc1133
Fix: decrement url test was set to increment.
2016-01-21 17:15:48 +01:00
Florian Bruhin
3c625790cc
Don't crash if JS tab is closed twice.
...
Fixes #906 .
2016-01-20 21:24:51 +01:00
Florian Bruhin
6bd092a948
tests: Skip custom_environment_no_system on Win.
...
Seems like it's broken on AppVeyor for some reason.
2016-01-20 20:34:19 +01:00
Florian Bruhin
4c64619263
tests: Fix configdir None tests for UserStyleSheet.
2016-01-20 19:55:34 +01:00
Michael Ilsaas
c33e9555a1
Tester for url increment/decrement with zeroes
2016-01-20 19:38:03 +01:00
Florian Bruhin
c02183652f
Fix starting with -c "" and add test.
...
Fixes #1169 .
2016-01-20 18:20:19 +01:00
Florian Bruhin
03118bd804
tests: Add a quteproc_new fixture.
...
This can be used to spawn a dedicated qutebrowser subprocess for a given test,
e.g. to test specific commandline arguments.
2016-01-20 18:19:29 +01:00
Florian Bruhin
039ae74662
tests: pass HOME to testprocess with custom env.
2016-01-20 18:19:05 +01:00
Florian Bruhin
10f3617b5e
tests: Only pass DISPLAY if it exists in the env.
2016-01-20 08:51:15 +01:00
Florian Bruhin
037be96718
tests: Increase testprocess.start timeout on CI.
...
Under some circumstances, starting qutebrowser needs more than 30 seconds
there.
2016-01-20 08:49:25 +01:00
Florian Bruhin
a249d8d426
tests: Ignore another Qt warning by hypothesis.
2016-01-20 08:06:36 +01:00
Florian Bruhin
258855cf50
tests: Don't wait for testprocess if it quits.
2016-01-20 07:47:50 +01:00
Florian Bruhin
e944239ae8
tests: Simplify QuitPythonProcess.
2016-01-20 07:38:27 +01:00
Florian Bruhin
28258be599
tests: Add arg to set custom env for testprocess.
2016-01-20 07:34:56 +01:00
Florian Bruhin
d3f0c27a87
tests: Add testprocess.wait_for_quit.
...
This was in conftest.py before, but we might want to use it outside of that as
well.
2016-01-20 06:54:00 +01:00
Florian Bruhin
ef17c86586
tests: Allow custom args when starting testprocess.
2016-01-20 06:53:25 +01:00
Florian Bruhin
eb276df876
Handle empty term in urlutils._get_search_url.
...
Fixes #1239 .
2016-01-19 07:03:43 +01:00
Florian Bruhin
d9a58547b0
bdd: Add some more waiting to :undo tests.
2016-01-19 06:16:07 +01:00
Florian Bruhin
faed088735
Wait until tabs are loaded for last-close tests.
2016-01-18 23:08:16 +01:00
Florian Bruhin
dfcd3087c2
Increase timeout for test_quteprocess_quitting.
2016-01-18 23:00:41 +01:00
Florian Bruhin
1892915146
bdd: Increase timeout for should_quit even more.
2016-01-18 22:13:24 +01:00
Florian Bruhin
8a757c8603
Release v0.5.1.
2016-01-18 22:12:52 +01:00
Felix Van der Jeugt
7ad871fab1
Merge remote-tracking branch 'source/master'
2016-01-18 21:45:47 +01:00
Florian Bruhin
111f46adc5
bdd: Increase timeout for should_quit.
2016-01-18 08:11:38 +01:00
Florian Bruhin
9394f13a08
tests: Update hello.txt.html for pygments 2.1.
2016-01-18 08:11:38 +01:00
Florian Bruhin
3bf20c7c7b
tests: Adjust check_contents comparison.
...
When doing the read() during the assert we'd get a weird pytest output which
doesn't make sense.
2016-01-18 08:11:35 +01:00
Florian Bruhin
3864ae8aae
bdd: Wait until page is loaded (last-close tests).
2016-01-18 07:33:17 +01:00
Florian Bruhin
c8538bdbb8
Fix config validation for String types.
...
Fixes #1231 .
2016-01-18 07:29:15 +01:00
Florian Bruhin
f7784e641e
bdd: Add some tests for tabs -> last-close.
2016-01-18 07:08:07 +01:00
Florian Bruhin
d6fafd474b
pylint: Disable no-member for http.client.*
...
Seems like this is potentially the same issue as
https://github.com/PyCQA/pylint/issues/399 , it also happens on the same
machines.
2016-01-17 21:27:24 +01:00
Florian Bruhin
0936ed4e61
Disable useless-suppression in webserver_sub_ssl.
...
Seems like this pylint bug doesn't happen on all systems...
2016-01-17 21:21:26 +01:00
Florian Bruhin
11dc51031d
tests: Increase timeout for quteprocess_quitting.
2016-01-17 21:20:28 +01:00
Florian Bruhin
9c5974c054
bdd: Add a "qutebrowser should quit" step.
2016-01-17 20:59:39 +01:00
Florian Bruhin
6e390bdc01
tests: Add a quteproc test for quitting.
2016-01-17 20:46:55 +01:00
Felix Van der Jeugt
9a889c6866
extended tests to cover new file argument
2016-01-17 20:38:33 +01:00
Florian Bruhin
6c5e158fc5
tests: Add a test for a quitting testprocess.
2016-01-17 20:19:41 +01:00
Florian Bruhin
dd211adf0f
tests: Make sure testprocess raises if start fails.
2016-01-17 20:18:07 +01:00
Florian Bruhin
6774894e9e
tests: Check HTTP server status per path.
...
Stricter and simpler, ha! :)
2016-01-15 07:13:45 +01:00
Florian Bruhin
40721a2b6b
bdd: Wait until basic-auth page is fully loaded.
...
This hopefully fixes this flakyness in
test_successful_webpage_authentification:
tests/integration/features/test_prompts.py:129:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
[...]
tests/integration/features/conftest.py:381: in check_contents_json
actual = json.loads(content)
/usr/lib/python3.4/json/__init__.py:318: in loads
return _default_decoder.decode(s)
/usr/lib/python3.4/json/decoder.py:343: in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
[...]
> raise ValueError(errmsg("Expecting value", s, err.value)) from None
E ValueError: Expecting value: line 1 column 1 (char 0)
2016-01-15 06:51:48 +01:00
Florian Bruhin
6420cdaa26
bdd: Open geolocation/notification page in new tab
...
This hopefully fixes this flaky error in test_notifications_with_ask__true on
OS X:
Failed: Logged unexpected errors:
LogLine('22:40:06 DEBUG js webpage:javaScriptConsoleMessage:531 [http://localhost:57758/data/prompt/notifications.html:28 ] [FAIL] unknown initial value for Notification.permission: denied')
[...]
testprocess.WaitForTimeout: Timed out after 15000ms waiting for {'message': 'Entering mode KeyMode.* (reason: question asked)'}.
2016-01-15 06:44:01 +01:00
Florian Bruhin
5856b24d20
bdd: Compare HTTP status to a whitelist.
...
401 (authorization required) is not < 400, and it makes more sense to be strict
here anyways.
2016-01-14 22:34:26 +01:00
Florian Bruhin
cda6d7c06d
bdd: Add test for webpage authentication.
2016-01-14 22:27:09 +01:00
Florian Bruhin
573654ece1
bdd: Add check_contents_json.
2016-01-14 22:27:00 +01:00
Florian Bruhin
c79f013050
bdd: Allow to load a page without waiting for it.
2016-01-14 22:26:42 +01:00
Florian Bruhin
23107a242b
bdd: Ignore POSITION_UNAVAILABLE for geolocation.
2016-01-14 20:40:46 +01:00
Florian Bruhin
0b116729f7
bdd: Fix skipping tests from JS.
...
With the previous solution, we'd call pytest.skip on teardown only, which means
the rest of the test (e.g. because of a wait_for) could still fail.
2016-01-14 20:32:17 +01:00
Florian Bruhin
b8a50dc475
bdd: Log error code on geolocation errors.
2016-01-14 19:04:48 +01:00
Florian Bruhin
e7a816c0c0
bdd: Skip geolocation tests if it's unavailable.
...
This should unbreak the build with older Qt versions.
2016-01-14 18:51:28 +01:00
Florian Bruhin
9c87eaf371
bdd: Allow to skip a test from JS.
...
This is a bit tricky since the test will actually run, but be marked as
skipped. The problem is we can't raise a pytest.skip.Exception during a test,
or it'll show up as an exception in a virtual Qt method.
Still this is better than nothing.
2016-01-14 18:50:36 +01:00
Florian Bruhin
14ff684e99
bdd: Add a xfail_norun marker.
2016-01-14 07:53:00 +01:00
Florian Bruhin
cf09e477a4
bdd: Add some tests for HTML5 notifications.
2016-01-14 07:49:39 +01:00
Florian Bruhin
1ddf817f4c
bdd: Add some tests for geolocation.
2016-01-14 07:30:52 +01:00
Florian Bruhin
252dc5bf1b
bdd: Add ability to fail tests from javascript.
2016-01-14 07:03:55 +01:00
Florian Bruhin
1d63e2dff4
bdd: Make "I wait for a prompt" step explicit.
2016-01-14 07:03:55 +01:00
Florian Bruhin
abcb366c12
bdd: Add some more SSL tests.
2016-01-13 22:36:45 +01:00
Florian Bruhin
d0fda5467a
bdd: Add a "I wait for a prompt" step.
2016-01-13 22:36:45 +01:00
Florian Bruhin
9c2a38938d
bdd: Clear SSL errors before SSL test.
2016-01-13 22:36:45 +01:00
Florian Bruhin
0e631a2c11
bdd: Mark should_be_logged messages as expected.
2016-01-13 22:36:45 +01:00
Florian Bruhin
2fbf218a0f
bdd: Use textwrap.dedent.
2016-01-13 18:29:14 +01:00
Florian Bruhin
7ccc58bb68
Remove empty line.
2016-01-13 18:13:16 +01:00
Florian Bruhin
6c916d166d
Merge branch 'master' of https://github.com/hcraT/qutebrowser into hcraT-master
2016-01-13 18:12:37 +01:00
Florian Bruhin
e17a332400
Fix lint.
2016-01-13 07:01:31 +01:00
Florian Bruhin
0ca9cd361a
Fix webserver_sub_ssl file header.
2016-01-13 00:00:55 +01:00
Florian Bruhin
f515165140
Add docstring.
2016-01-12 23:51:36 +01:00
Florian Bruhin
5f2ca88176
bdd: Don't test exact SSL error text.
...
Turns out those are platform specific.
2016-01-12 23:50:25 +01:00
Florian Bruhin
9479b65d25
bdd: Add first SSL test.
2016-01-12 23:35:48 +01:00
Florian Bruhin
8dd7f080f4
tests: Default to 5s timeout if not on CI.
2016-01-12 22:49:54 +01:00
Florian Bruhin
adbdfcbad3
tests: Add an SSL server subprocess.
2016-01-12 22:48:38 +01:00
Florian Bruhin
25dbf3731b
tests: Split wait_for_load_finished from open_path.
2016-01-12 22:47:09 +01:00
Florian Bruhin
df03099468
Fix completion for String config type.
...
Since 2a705e2eb6
non-specialized config types are
String. However, String had an overloaded complete() which defaulted to
returning None.
Now we use the normal complete() which relies on valid_values if completions
isn't given instead.
Fixes #1223 .
2016-01-12 18:53:53 +01:00
Tarcisio Fedrizzi
f813bc2415
Adds unit test to check that paths ending with newlines are handled
...
correctly
2016-01-12 11:27:11 +01:00
Tarcisio Fedrizzi
5917bbbe5c
Fixes wrong indentation in multiline clipboard text
2016-01-12 11:25:14 +01:00
Tarcisio Fedrizzi
524341fd7a
Use textwrap.dedent to parse multiline clipboard text
2016-01-12 11:24:31 +01:00
Tarcisio Fedrizzi
f08704e789
Adds function to insert multiple lines in the clipboard
2016-01-12 09:59:03 +01:00
Florian Bruhin
22d255f49f
bdd: Skip JS prompt() tests on PyQt < 5.3.1.
...
Those versions had a PyQt bug when overloading javaScriptPrompt, so we don't do
that there.
2016-01-12 09:04:03 +01:00
Florian Bruhin
df40b39e3e
Work around pytest madness.
2016-01-12 08:20:08 +01:00
Florian Bruhin
046194ad6f
bdd: Add first tests for JS prompt/confirm/alert.
2016-01-12 08:04:56 +01:00
Florian Bruhin
3f21accaeb
tests: Use sip.delete to clean up prompt.
...
It looks like using deleteLater and waiting for the destroyed signal took too
long on the buildbot: http://www.qutebrowser.org/testresults/osx/1245.html
2016-01-11 07:38:58 +01:00
Florian Bruhin
70cd18fc98
100% coverage for mainwindow/statusbar/prompt.py.
2016-01-11 07:14:51 +01:00
Florian Bruhin
20610807c1
tests: Add missing files.
2016-01-10 22:08:52 +01:00
Florian Bruhin
97d5342f0c
Adjust hypothesis setting for 2.0.
2016-01-10 21:57:06 +01:00
Florian Bruhin
fce4351463
bdd: Add some tests for quickmarks.
2016-01-10 21:21:32 +01:00
Tarcisio Fedrizzi
1b31a3fee4
Allows to paste multiple URLs
...
- The paste command will now open one tab/window per url if multiple
URLs (separated by newline) are present in the clipboard
- Adds the tests for the new multitab functionality
- Changes test/integration/conftest.py to be able to insert newlines in
the clipboard for the test
2016-01-09 11:32:12 +01:00
Florian Bruhin
c385580b81
bdd: Add some tests for bookmarks.
2016-01-09 00:15:57 +01:00
Florian Bruhin
4ef0c3e09f
tests: Ensure lines look right when checking tabs.
2016-01-09 00:14:57 +01:00
Florian Bruhin
8ca85b9c66
Also show testprocess output on teardown errors.
2016-01-08 12:53:36 +01:00
Florian Bruhin
ab79cd2496
tests: Avoid pytrace=False for now.
...
Using pytest.fail with pytrace=False hides the quteprocess output, which makes
it a lot harder to debug stuff.
This is because TestReport.longrepr is suddenly a string and we can't add infos
to it - see https://github.com/pytest-dev/pytest/issues/1316
2016-01-08 12:35:12 +01:00
Florian Bruhin
ff2024a565
Add socket IDs to ipc debug messages.
2016-01-08 12:02:36 +01:00
Florian Bruhin
ab0cd17772
Fix lint.
2016-01-08 10:00:42 +01:00
Florian Bruhin
9ed79ad57d
tests: Switch to qtbot.assertNotEmitted.
2016-01-08 10:00:42 +01:00
Florian Bruhin
f004e45566
tests: Remove pointless CookieJar test.
...
There's no code between those two lines which could possibly emit that signal.
2016-01-08 09:57:04 +01:00
Florian Bruhin
1fb34331e5
tests: Default to raising=True for qtbot.
...
- qtbot.waitSignal with raising=True is the default this way, so we remove the
raising=True.
- qtbot.waitSignal with raising=False stay untouched
- Some qtbot.waitSignal without raising had one added (because we don't want it
to raise)
- Some qtbot.waitSignal without raising actually should've raised, which they
do now.
2016-01-08 09:49:06 +01:00
Florian Bruhin
eebed7a5a7
tests: Poll clipboard for changes.
...
For some reason I can't explain, since 2b0870084b
we got test failures on OS X, as the clipboard had the old value before waiting
for the change, the new (correct) value after waiting for it, but never
actually emitted 'changed'.
We could just re-check the contents after the timeout, but that'd mean we wait
1s for every test where this weird thing happens.
Instead, we poll the clipboard for every 100ms as long as the timeout (1s)
hasn't passed, and return as soon as it has the correct contents.
2016-01-08 09:35:03 +01:00
Florian Bruhin
eef1604dcd
tests: Improve WaitForClipboardTimeout message.
2016-01-08 08:35:34 +01:00
Florian Bruhin
0d9cbba3b9
tests: Dump contents in WaitForClipboardTimeout.
2016-01-08 01:56:27 +01:00
Florian Bruhin
aecf410707
Make pylint shut up about pytest.config.
2016-01-08 01:16:58 +01:00
Florian Bruhin
2b0870084b
bdd: Run :tab-only between tests for caret/search.
...
Otherwise we end up opening a lot of tabs which slow down qutebrowser,
The latest issue in #1183 might actually be caused by that.
2016-01-08 00:58:01 +01:00
Florian Bruhin
5eafccb604
tests: Print logs live when -s is given.
2016-01-07 21:15:24 +01:00
Florian Bruhin
9e9cedf3e0
tests: Shorten (not suppress) quteproc log w/o -v.
...
The output was almost always useless without -v because the debug log wasn't
shown at all, only error/info.
Now we display a maximum of 50 lines (regardless of what level) without -v.
2016-01-07 19:41:49 +01:00
Florian Bruhin
df6d9d741f
bdd: Add search tests for known bugs/regressions.
...
This adds a test for #874 , #507 and #940 .
2016-01-07 19:41:26 +01:00
Florian Bruhin
37022b8c45
bdd: Improve search tests.
2016-01-07 08:21:18 +01:00
Florian Bruhin
18b5860584
bdd: Add "When I open ... in a new window" step.
2016-01-07 08:20:48 +01:00
Florian Bruhin
f9645e447a
bdd: Add first tests for searching.
2016-01-07 07:49:45 +01:00
Florian Bruhin
6a592576eb
bdd: Fix timeout exception in _wait_for_clipboard.
2016-01-07 07:43:36 +01:00
Florian Bruhin
360f0b6180
bdd: Improve :inspector tests.
2016-01-07 07:12:51 +01:00
Florian Bruhin
ab22b7740f
bdd: Add test for :follow-selected --tab with JS.
2016-01-06 23:29:16 +01:00
Florian Bruhin
c9a35e7f1e
bdd: Add a test for :follow-selected --tab
2016-01-06 23:24:17 +01:00
Florian Bruhin
7cc98a1248
Fix lint.
2016-01-06 23:19:44 +01:00
Florian Bruhin
16ec035418
bdd: Handle trailing slash for URLs loaded.
...
For some reason, older Qt versions (Debian Jessie/Ubuntu Trusty) like to add a
/, so we need to handle that case too.
2016-01-06 23:19:04 +01:00
Florian Bruhin
a2c3f8c402
bdd: Add some tests for :follow-selected.
2016-01-06 22:59:42 +01:00
Florian Bruhin
916b294976
bdd: Fix regex escape.
...
The . chars weren't properly escaped.
2016-01-06 22:59:05 +01:00
Florian Bruhin
7dc03710b1
bdd: Only check logs for "... should be loaded".
...
Checking the requests from the webserver proved problematic, as often there's
some kind of caching going on. Instead, we only check the log, as this is used
for things like :navigate anyways, so if the log says the page got loaded, we
can trust it.
There's still "... should be requested" to check the actual requests.
2016-01-06 22:57:49 +01:00
Florian Bruhin
b1bf75f069
bdd: Add a test for :drop-selection.
2016-01-06 22:15:13 +01:00
Florian Bruhin
2d9900a5ad
bdd: Add test for :paste with invalid URL.
2016-01-06 22:07:19 +01:00
Florian Bruhin
bd611b7ee4
bdd: Skip :print test.
...
This sometimes seem to cause the following warning:
QPainter:🔚 Painter ended with 2 saved states
2016-01-06 18:27:14 +01:00
Florian Bruhin
275f1ede82
bdd: Add test for :undo.
2016-01-06 18:27:14 +01:00
Florian Bruhin
4bb38f1488
bdd: Handle some more corner cases in commands.py.
2016-01-06 18:27:14 +01:00
Florian Bruhin
4099a40e35
Fix lint.
2016-01-06 08:50:22 +01:00
Florian Bruhin
d2a1282c0b
tests: Split up testprocess.wait_for.
2016-01-06 08:49:30 +01:00
Florian Bruhin
b1b767ed96
tests: Don't start Xvfb for unittests-nodisp.
2016-01-06 08:36:40 +01:00
Florian Bruhin
b0f001d3f1
Skip :print test when window can't be focused.
...
For some reason the window doesn't get focused on Travis. If that happens,
let's just skip the test instead of failing it.
2016-01-06 08:29:53 +01:00
Florian Bruhin
29dd6af976
tests: Optionally skip a test when waiting for log.
2016-01-06 08:29:46 +01:00
Florian Bruhin
6a97e98007
Fix lint.
2016-01-06 07:55:42 +01:00
Florian Bruhin
02e30873e1
Only test :print on Linux.
2016-01-06 07:54:54 +01:00
Florian Bruhin
fc755c104b
bdd: Add test for exception with :pyeval.
2016-01-06 07:42:33 +01:00
Florian Bruhin
03ebdfd641
bdd: Add tests for :pyeval.
2016-01-06 07:15:42 +01:00
Florian Bruhin
677dcd6748
bdd: Add tests for :print.
2016-01-06 07:15:34 +01:00
Florian Bruhin
2cadac6b6e
bdd: Add tests for :stop/:reload with wrong count.
2016-01-06 07:15:20 +01:00
Florian Bruhin
e2994e9375
bdd: Add "the page should contain the plaintext".
2016-01-06 07:15:06 +01:00
Florian Bruhin
1619b89df7
pytest: Add a skip mark for use with bdd.
2016-01-06 07:14:30 +01:00
Florian Bruhin
f943891ce6
Fix :reload test when :stop is skipped.
...
I don't know why, but :stop being skipped causes something to be cached with
hello2.txt.
2016-01-05 22:46:52 +01:00
Florian Bruhin
0ce9b28da7
Skip :stop test on OS X.
...
This triggers the OS X kernel bug explained here:
https://bitbucket.org/cherrypy/cherrypy/pull-requests/117/
Fixes #1183 .
2016-01-05 20:13:25 +01:00
Florian Bruhin
8bd4d3d24a
Release v0.5.0
2016-01-05 19:30:50 +01:00
Florian Bruhin
d75ee78845
Clean up pdfjs tests.
2016-01-05 18:47:50 +01:00
Florian Bruhin
88d28e690e
Add pdf.js version to qute:version.
2016-01-05 18:47:50 +01:00
Florian Bruhin
a97ba9aa09
Merge branch 'pdfjs' of https://github.com/Kingdread/qutebrowser into Kingdread-pdfjs
2016-01-05 07:21:26 +01:00
Florian Bruhin
705d77abfb
Also handle the doc path not existing at all.
2016-01-04 20:36:15 +01:00
Florian Bruhin
20faecc7a0
Also handle inexistant doc path.
2016-01-04 20:35:16 +01:00
Florian Bruhin
ea182934f3
Update docs for :help tests.
2016-01-04 20:10:17 +01:00
Florian Bruhin
a5f2ac5f03
Adjust copyright years.
2016-01-04 07:12:39 +01:00
Florian Bruhin
c1d3a94936
Don't pass through shifted characters.
...
See #1207 - turns out that was a problem for *any* character.
2016-01-04 07:10:23 +01:00
Florian Bruhin
81e1c72588
pylint: unneeded-suppression -> useless-suppression
2015-12-21 10:02:43 +01:00
Florian Bruhin
168f65b1a4
tests: Use caplog.at_level, not atLevel.
2015-12-21 09:52:33 +01:00
Florian Bruhin
9101046fe5
tests: Adjust error message comparison for Windows.
2015-12-21 09:51:25 +01:00
Florian Bruhin
95e67bba7b
Suppress pylint no-member for os.mkfifo.
2015-12-21 09:47:20 +01:00
Florian Bruhin
9f64dfb3b6
Skip all tests using py_proc when frozen.
2015-12-21 09:46:30 +01:00
Florian Bruhin
4b770f4f35
tests: Try to work around race condition.
2015-12-21 08:55:55 +01:00
Florian Bruhin
59c8e5c3d1
Add some tests for commands.userscripts.
2015-12-21 08:45:46 +01:00
Daniel Schadt
7944217da4
Adjust pdfjs unit tests for new logging level
...
The script generation output was changed because we changed the logging
level, this adjusts the unit tests to match the new output.
2015-12-20 20:14:17 +01:00
Florian Bruhin
2b1622b34d
Update to pytest-bdd 2.16.0.
...
This avoids deprecation warnings emitted by python 3.5 and pytest 2.8.
2015-12-20 20:11:49 +01:00
Daniel Schadt
6d02ef68ec
Add BDD tests for pdfjs integration
2015-12-20 20:00:56 +01:00
Daniel Schadt
f2ed14a24a
Add unit tests for browser.pdfjs
2015-12-20 19:24:41 +01:00
Daniel Schadt
0811418746
pdfjs: don't embed data in html
...
We don't need more than one copy of the pdf.
2015-12-20 19:24:41 +01:00
Daniel Schadt
dc9cd47afc
pdfjs: add unittest for script generation
2015-12-20 19:24:41 +01:00
Florian Bruhin
fc3a3ea8c6
Add missing not_frozen mark in test_guiprocess.
...
This should fix test failures when frozen.
2015-12-20 18:40:57 +01:00
Florian Bruhin
fcf94fd527
Remove various deprecated commands/arguments.
2015-12-20 18:38:29 +01:00
Florian Bruhin
6b89eb43a2
Allow any non-space char in search engine names.
...
Closes #1189 .
2015-12-20 17:22:54 +01:00
Florian Bruhin
5c769d8000
Report stdout/stderr of failed subprocesses.
2015-12-18 21:23:33 +01:00
Florian Bruhin
d3dc90cb2a
Revert "tests: Use urllib to load redirect-later-continue."
...
This reverts commit 1e43b882ae
.
Seems like this causes other trouble (the redirect-later request missing?!)
2015-12-18 20:24:03 +01:00
Florian Bruhin
1e43b882ae
tests: Use urllib to load redirect-later-continue.
...
This might avoid the EPROTOTYPE bug on OS X. See #1183 .
2015-12-18 19:57:15 +01:00
Florian Bruhin
b3e4ac8043
tests: Fix AttributeError in _wait_for_clipboard.
2015-12-18 07:18:27 +01:00
Florian Bruhin
45d6dc6aa3
tests: Hopefully fix keyinput.feature flakiness.
...
While the original "no focused webview" bug (with the first test after spawning
qutebrowser) from #1183 was fixed, we still had a case where the next test
after ":fake-key sending key to the website with other window focused" failed,
presumably because the inspector was still focused, e.g. here:
http://qutebrowser.org:8010/builders/osx/builds/1175/steps/tests/logs/stdio
This hopefully fixes this by properly waiting until the inspector is gone.
2015-12-18 07:13:16 +01:00
Florian Bruhin
172157ed0d
Remove unused import, take two.
2015-12-17 23:09:11 +01:00
Florian Bruhin
a7dee6c053
Remove unused import.
2015-12-17 22:57:16 +01:00
Florian Bruhin
fc84e58043
tests: Ignore "SelectionRequest too old" globally.
...
If we use pytestmark, it won't be ignored inside subprocess output, so our fix
from https://github.com/The-Compiler/qutebrowser/issues/1124#issuecomment-158073581
never actually worked.
See #1124 and #1183 .
2015-12-17 22:33:07 +01:00
Florian Bruhin
8786e979a6
tests: Wait for data in the clipboard.
...
This should hopefully stabilize the flaky clipboard tests.
See #1183 .
2015-12-17 22:17:38 +01:00