qutebrowser/tests/unit/utils
Florian Bruhin ebb3046822 Add overrides for mimetype -> extension conversion
Python 3.6 gets some of those "wrong":
https://bugs.python.org/issue1043134

This has been fixed in Python 3.7:
https://github.com/python/cpython/pull/14375

The override dict has been generated by copying the types_map from the
current git master:
https://github.com/python/cpython/blob/v3.10.0a3/Lib/mimetypes.py#L414-L547

And then running the following with Python 3.6:

    import mimetypes

    reverse = {}
    for ext, mimetype in types_map.items():
        if mimetype not in reverse:
            reverse[mimetype] = ext
    assert reverse['text/plain'] == '.txt'

    for mimetype, ext in reverse.items():
        got = mimetypes.guess_extension(mimetype)
        if got != ext:
            print(f'    "{mimetype}": "{ext}",  # not {got}')
2021-01-05 11:19:15 +01:00
..
usertypes Revert "Work around PyQt 5.15.1 waitSignals issues" 2020-11-24 18:48:19 +01:00
overflow_test_cases.py Adjust copyrights for 2020 2020-01-04 18:21:17 +01:00
test_debug.py Adjust copyrights for 2020 2020-01-04 18:21:17 +01:00
test_error.py Fix indent 2020-05-26 16:31:00 +02:00
test_javascript.py Make javascript.string_escape tests run with QtWebEngine 2020-08-11 20:23:08 +02:00
test_jinja.py Fix some a/an spelling mistakes 2020-09-06 16:37:59 +02:00
test_log.py Rename log.ignore_py_warnings and add action arg 2020-10-27 16:04:09 +01:00
test_qtutils.py tests: Update test_version_check 2020-11-20 12:10:50 +01:00
test_standarddir.py standarddir: Remove data moving support 2020-11-13 10:59:43 +01:00
test_urlmatch.py Initial drop of Python 3.5 2020-10-26 15:50:54 +01:00
test_urlutils.py Remove custom data: URL parsing 2021-01-05 11:19:15 +01:00
test_utils.py Add overrides for mimetype -> extension conversion 2021-01-05 11:19:15 +01:00
test_version.py tests: Clear module cache properly 2020-12-22 19:54:46 +01:00