leforestier / yattag

Python library to generate HTML or XML in a readable, concise and pythonic way.
333 stars 31 forks source link

1.14.0: pytest `DeprecationWarning` warnings #71

Closed kloczek closed 1 year ago

kloczek commented 2 years ago

I'm trying to package your module as an rpm package. So I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.

It would be good add proper pytest configuration to allow use pytest without params. Here is pytest output:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-yattag-1.14.0-6.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-yattag-1.14.0-6.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra test/tests_doc.py test/tests_indentation.py test/tests_simpledoc.py
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.13, pytest-7.1.1, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/yattag-1.14.0
collected 20 items

test/tests_doc.py ........                                                                                                                                           [ 40%]
test/tests_indentation.py ....                                                                                                                                       [ 60%]
test/tests_simpledoc.py ........                                                                                                                                     [100%]

============================================================================= warnings summary =============================================================================
test/tests_indentation.py:54
  /home/tkloczko/rpmbuild/BUILD/yattag-1.14.0/test/tests_indentation.py:54: DeprecationWarning: invalid escape sequence \.
    """\

test/tests_indentation.py:59
  /home/tkloczko/rpmbuild/BUILD/yattag-1.14.0/test/tests_indentation.py:59: DeprecationWarning: invalid escape sequence \.
    """\

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
====================================================================== 20 passed, 2 warnings in 0.08s ======================================================================
leforestier commented 1 year ago

Thanks for raising that issue. I changed the test files' names and I removed the deprecated escape sequences.