Commit Graph

22 Commits

Author SHA1 Message Date
Florian Bruhin 0718b25796 reuse: Initial copyright text update for myself
git ls-files | \
    xargs sed -Ei 's/Copyright [0-9]{4}(-[0-9]{4}) Florian Bruhin \(The Compiler\) <mail@qutebrowser\.org>/SPDX-FileCopyrightText: Florian Bruhin (The Compiler) <mail@qutebrowser.org>/'
2023-07-23 12:49:05 +02:00
Florian Bruhin b2aaba6043 reuse: Adjust most license headers
git ls-files | xargs grep -l "is free software"  | xargs reuse annotate --license="GPL-3.0-or-later" --skip-unrecognised
2023-07-23 12:11:07 +02:00
Philipp Albrecht d9e8b638bf Remove vim modelines
We're deprecating vim modelines in favor of `.editorconfig`.

Removing vim modelines could be done using two one-liners. Most of the vim modelines
were followed by an empty line, so this one-liner took care of these ones:

```sh
rg '^# vim: .+\n\n' -l | xargs sed -i '/^# vim: /,+1d'
```

Then some of the vim modelines were followed by a pylint configuration line, so running
this one-liner afterwards took care of that:

```sh
rg '^# vim:' -l | xargs sed -i '/^# vim: /d'
```
2023-06-30 11:03:06 +02:00
Florian Bruhin 6e48c9f1a9 Revert "lint: add stacklevel kwarg to warnings"
This reverts commit 47be6f3aeb.

This doesn't really make sense in test files, as the warning would point
inside some internal pytest code, which is not helpful.

Instead, let's just disable the corresponding flake8 warning in tests.
2023-03-14 11:57:24 +01:00
toofar 47be6f3aeb lint: add stacklevel kwarg to warnings
flake8-bugbear B028 No explicit stacklevel keyword argument found. The
warn method from the warnings module uses a stacklevel of 1 by default.
This will only show a stack trace for the line on which the warn method
is called. It is therefore recommended to use a stacklevel of 2 or
greater to provide more information to the user.

Semgrep helped:

    semgrep --lang=py -e 'warnings.warn($ARG)' --replacement 'warnings.warn($ARG, stacklevel=2)' $FILES -a
    semgrep --lang=py -e 'warnings.warn($ARG1, $ARG2)' --replacement 'warnings.warn($ARG1, $ARG2, stacklevel=2)' $FILES -a

Although it did lose the f-string on one of them.
2023-02-26 13:39:35 +13:00
Florian Bruhin 1a4fff1a42 doc: Switch URLs to https 2021-01-26 15:19:01 +01:00
Florian Bruhin 222f1f19a1 Bump copyright years
Closes #6015
2021-01-20 20:06:19 +01:00
Florian Bruhin 9e4276db9b Adjust copyrights for 2020 2020-01-04 18:21:17 +01:00
Jay Kamat 3e816f5f8b
Update copyright for 2019 2019-02-22 21:45:08 -08:00
Florian Bruhin 6f028e9ad0 Update copyright years 2018-02-05 12:19:50 +01:00
Florian Bruhin 822623f2ed Finally update copyrights... 2017-05-09 21:37:03 +02:00
Florian Bruhin de50f30b9b Replace all GitHub links 2017-02-05 00:13: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 a5f2ac5f03 Adjust copyright years. 2016-01-04 07:12:39 +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
Florian Bruhin 7e8f16dd22 pylint: Disable deprecated-method in test_conftest. 2015-12-01 07:16:53 +01:00
Florian Bruhin 0d67cff5cb Merge branch 'bdd'
Conflicts:
      tests/test_conftest.py
      tox.ini
2015-11-02 06:36:30 +01:00
Florian Bruhin 7d17957e90 Ignore inspect.getargspec() warning during tests.
https://github.com/pytest-dev/pytest-bdd/issues/153
2015-11-01 22:40:11 +01:00
Florian Bruhin 021a379dd2 Add xfailed test for #1070. 2015-10-26 21:02:34 +01:00
Florian Bruhin 65891c6f0d Fail tests on Python warnings.
Fixes #982.
2015-10-01 21:34:00 +02:00
Florian Bruhin f552f433f8 Rename stupidly named test. 2015-10-01 18:58:45 +02:00
Florian Bruhin 1861b0a5e4 Don't skip all tests without DISPLAY set.
We used qapp in a session scoped fixture, which means testing without DISPLAY
skipped all tests.
2015-09-28 21:50:44 +02:00