view pytest.ini @ 8307:e965ff6f8cb3

setup: avoid bleach 3.1.4 for now - it seems to deliberately cause regressions See https://github.com/mozilla/bleach/blob/master/CHANGES and https://github.com/mozilla/bleach/commit/d6018f2539d271963c3e7f54f36ef11900363c69 ... which adds xfails for use cases similar to how we use bleach. It would completely remove style attributes instead of dropping bad parts of them, as shown by the markup_renderer.py doctest it made fail: >>> MarkupRenderer.render('''<img id="a" style="margin-top:-1000px;color:red" src="http://example.com/test.jpg">''', '.md') Expected: '<p><img id="a" src="http://example.com/test.jpg" style="color: red;"></p>' Got: '<p><img id="a" src="http://example.com/test.jpg" style=""></p>' Until a better solution is found, stick to 3.1.3 and accept the potential ReDoS.
author Mads Kiilerich <mads@kiilerich.com>
date Thu, 26 Mar 2020 18:12:52 +0100
parents afa5e0bdb76f
children
line wrap: on
line source

[pytest]
# only look for tests in kallithea/tests
python_files = kallithea/tests/**/test_*.py
addopts =
    # --verbose
    # show extra test summary info as specified by chars (f)ailed, (E)error, (s)skipped, (x)failed, (X)passed, (w)warnings.
    -rfEsxXw
    # Shorter scrollbacks; less stuff to scroll through
    --tb=short
    #
    --doctest-modules
    --doctest-ignore-import-errors