Florian Bruhin
a370a00194
Remove more useless-return suppressions
2018-08-19 10:53:01 +02:00
Florian Bruhin
e50b6912a7
Fix pylint 2.0 useless-return cases
...
See https://github.com/PyCQA/pylint/issues/2300
2018-07-16 14:33:11 +02:00
Florian Bruhin
42a3622906
Ignore a new Qt 5.11 lowlevel message
2018-07-03 15:38:29 +02:00
Florian Bruhin
4d1e56a8c6
Ignore "Lost UI shared context" error happening on AppVeyor
2018-07-03 13:39:34 +02:00
Florian Bruhin
a02c25dfb1
Don't escape URLs for qute://history
...
We only use the URL to set a 'href' attribute, which does not need escaping.
See #4011
Fixes #4012
2018-06-23 14:27:07 +02:00
Florian Bruhin
9a5439e5d0
Re-add waiting for QQuickWidget
...
Apparently this is still needed on some PyQt versions.
2018-06-21 22:22:04 +02:00
Florian Bruhin
62d8b5b574
Don't depend on PyQt5.QtQuickWidgets to get RWHV
...
Some distributions (at least FreeBSD) don't package that module, so let's not
rely on it.
2018-06-21 17:14:29 +02:00
Florian Bruhin
ec88c15390
Fix waiting for initial focus object with Qt 5.11 workarounds
...
This was broken in d32d541ac0
because now
apparently PyQt knows it's a QQuickWidget.
2018-06-09 20:05:26 +02:00
Florian Bruhin
11b957f24b
tests: Adjust getting markers for pytest 3.6
2018-06-07 19:29:01 +02:00
Florian Bruhin
e789296b7f
Handle new focus object for Qt 5.11
...
See https://codereview.qt-project.org/#/c/221408/10 and #3661 :
https://github.com/qutebrowser/qutebrowser/issues/3661#issuecomment-375969315
2018-04-23 16:54:47 +02:00
Florian Bruhin
00bdb60627
Ignore "Dropping message on closed channel." message
...
This seems to happen with this test in tabs.feature with Qt 5.11:
Scenario: :buffer with wrong argument (-1)
It only happens ~1/50 times though, and seems like some Qt bug.
See #3661
2018-03-23 07:59:46 +01:00
Florian Bruhin
33066af51d
Break long comment
2018-03-19 13:59:30 +01:00
Florian Bruhin
6a971e2846
Ignore OnDidStopLoading error message
...
See #3661 , https://bugreports.qt.io/browse/QTBUG-66661
2018-03-19 12:13:10 +01:00
Florian Bruhin
8a3d9c0c01
Adjust ignored log messages for Qt 5.11
2018-03-18 18:58:29 +01:00
Florian Bruhin
b906d92053
Remove now uneeded pylint ignore
2018-02-27 10:06:11 +01:00
Florian Bruhin
52b5492c6a
Merge branch 'per-url'
2018-02-25 19:44:51 +01:00
Florian Bruhin
4c147b77c1
Add a test for the error page workaround
2018-02-25 16:35:02 +01:00
Florian Bruhin
98b2b67b8b
Add tests for per-URL JavaScript settings
2018-02-23 15:08:07 +01:00
Jonathan Berglind
681bb058fa
Use HTTPStatus enum instead of http.client in webserver fixture
2018-02-13 20:57:05 +01:00
Jonathan Berglind
3d5bba9cff
Use HTTPStatus in flask test server
2018-02-13 20:57:05 +01:00
Jonathan Berglind
81acba4700
Use HTTPStatus for existing tests, add more ones
...
Add tests for endpoints being refactored
2018-02-13 20:56:59 +01:00
Florian Bruhin
aa5da1b312
Don't set up YAML constructors/resolvers for default loaders
...
After reading https://pyyaml.org/wiki/PyYAMLDocumentation again, turns out
Loader.add_constructor and .add_implicit_resolver are actually *class* methods.
In other words, we've been adding dozens of constructors/resolvers to the
default YAML loader object, causing it to slow down massively in other tests
which call configdata.init().
Instead, create our own loader class and only add them once there.
I'm still not sure why this caused the duration to increase with every YAML load
though - that might still be some kind of bug in PyYAML.
Fixes #2777
2018-02-10 19:35:03 +01:00
Florian Bruhin
6f028e9ad0
Update copyright years
2018-02-05 12:19:50 +01:00
Florian Bruhin
c8de4675db
Various spelling fixes
2018-02-04 21:30:59 +01:00
Florian Bruhin
f2c93a0061
Use request instead of pytestconfig
...
This unifies QuteProc and the other Process subclasses a bit.
2017-12-19 08:55:35 +01:00
Florian Bruhin
12ba642547
Avoid using pytest.config
...
It's going to be removed in some future pytest release.
2017-12-19 08:32:32 +01:00
Florian Bruhin
430126dcc8
pylint: Re-enable ungrouped-imports
2017-12-15 23:08:53 +01:00
Florian Bruhin
e65c0dd8a7
pylint: Re-enable bad-continuation
...
And lots and lots of whitespace changes.
2017-12-15 19:16:55 +01:00
Florian Bruhin
f4ed31b295
Add an utils.Unreachable exception
2017-12-15 16:33:47 +01:00
George Edward Bulmer
4844a68bfc
Change a rogue re.fullmatch into a re.search.
...
Sometimes tests were timing out. Perhaps with fullmatch these tests were
rarely failing to parse the logs for the information.
2017-12-12 21:42:10 +00:00
George Edward Bulmer
9ca6baca4f
Modify instances of re.match to fullmatch or search.
...
This applies the changes to the tests directory only.
2017-12-12 15:07:37 +00:00
Florian Bruhin
2e8acf4825
Improve terminating of test processes
...
There are various small changes here:
- If the process is already finished, we don't try to terminate it.
- On Windows, we use QProcess::kill instead of QProcess::terminate, as terminate
will only work with processes which have a GUI loop.
- We assert that quitting the suprocess actually worked.
Fixes #3384
2017-12-12 09:36:28 +01:00
Florian Bruhin
6655793e6a
Use 'terminate' to clean up webserver subprocess
...
We already have TestProcess.terminate which does exactly the same
WebserverProcess.cleanup does.
See #3384
2017-12-12 09:33:34 +01:00
Florian Bruhin
3cd2910fa2
Merge branch 'greasemonkey' of https://github.com/toofar/qutebrowser into greasemonkey
2017-12-06 10:47:29 +01:00
Florian Bruhin
62228752aa
Fix most end2end tests with Qt 5.10
...
For some reason, if we don't wait for about:blank to be fully loaded with
Qt 5.10, we get the next LoadStatus.finished notification with about:blank as
URL.
This is most likely caused by the changes in
https://codereview.qt-project.org/#/c/202924/
See #3003
2017-12-05 08:34:33 +01:00
Florian Bruhin
a8f4444c24
tests: Show more of the message
2017-12-04 22:07:49 +01:00
Florian Bruhin
b554e1f763
tests: Add after= argument to wait_for
2017-12-04 22:07:23 +01:00
Florian Bruhin
2752055281
Fix lint in webserver_sub.py
2017-11-29 22:17:48 +01:00
Florian Bruhin
0e80be2d30
Clear end2end test data again after initializing
...
If we don't do this, earlier tests can affect later ones when e.g. using "...
should not be logged", as we don't really wait until a test has been fully
finished.
2017-11-27 20:10:38 +13:00
Florian Bruhin
03a9cbdfb4
Break long lines
...
(cherry picked from commit 18a45bbd5b0492785cfc6e9b541d816ed8ec5c54)
2017-11-24 16:03:34 +01:00
Florian Bruhin
06fc52321e
Ignore new Qt 5.9.3 error message
2017-11-24 14:24:15 +01:00
Florian Bruhin
72d466d236
Break long lines
2017-11-22 11:34:10 +01:00
Florian Bruhin
aa417019ae
Try stabilizing loading about:blank in end2end tests
2017-11-22 07:59:22 +01:00
Florian Bruhin
54af872825
Add missing comma
2017-11-21 10:45:49 +01:00
Florian Bruhin
a5d9661d73
Simplify is_ignored_lowlevel_message
2017-11-20 19:29:31 +01:00
Florian Bruhin
abb5c9f638
Ignore Qt 5.7 OpenSSL logging message
2017-11-20 13:58:37 +01:00
Florian Bruhin
3b680d0bff
Pass --disable-seccomp-filter-sandbox for tests with Qt 5.7.1
...
This is a stop-gap so I'm able to run end2end tests at least.
See #3163 .
For unit tests, we need https://github.com/pytest-dev/pytest-qt/pull/193 first.
2017-11-20 13:54:52 +01:00
Florian Bruhin
fdc43438ef
Make tests for non-ASCII files work
2017-11-07 17:00:08 +01:00
Florian Bruhin
023c59f8c0
Reset the webserver process correctly between tests
...
If we don't call before_test(), if the server shows an error, all following
tests will fail.
See #3207
2017-10-28 17:29:55 +02:00
Florian Bruhin
94f8bb9574
bdd tests: Make sure initial about:blank check is redone on restart
...
When we did "Given I have a fresh instance", we immediately did run the commands
without waiting for the initial about:blank load again.
With Qt 5.10, this causes issues as the loadFinished signal is emitted with
about:blank then, and not the real URL.
See #3003
2017-10-25 14:06:55 +02:00