|
From: Michał G. <mgo...@us...> - 2024-04-11 17:18:14
|
The patch fixes the failure. Thanks!
---
**[bugs:#484] 0.21.1: `test_writers.test_html5_polyglot_parts.Html5WriterPublishPartsTestCase` test failures**
**Status:** open
**Created:** Thu Apr 11, 2024 02:44 PM UTC by Michał Górny
**Last Updated:** Thu Apr 11, 2024 04:14 PM UTC
**Owner:** nobody
0.21.1 introduced three test regressions. The two of them are specific to `test_writers.test_html5_polyglot_parts.Html5WriterPublishPartsTestCase`. The errors are:
```
$ python3.10 alltests.py
Testing Docutils 0.21.1 with Python 3.10.14 on 2024-04-11 at 16:42:02
OS: Linux 6.8.4-gentoo-dist #1 SMP PREEMPT_DYNAMIC Fri Apr 5 12:29:35 -00 2024 (linux, Linux-6.8.4-gentoo-dist-x86_64-AMD_Ryzen_5_3600_6-Core_Processor-with-glibc2.39)
Working directory: /tmp/docutils/test
Docutils package: /tmp/docutils/docutils
.....................................................................s.................................................................................................................................................................................................................s.....................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................s..........................................................................................................EEE...........................................................................................
======================================================================
FAIL: test_publish (test_writers.test_html5_polyglot_parts.Html5WriterPublishPartsTestCase) (id="totest['syntax_highlight'][0]")
----------------------------------------------------------------------
Traceback (most recent call last):
File "/tmp/docutils/test/test_writers/test_html5_polyglot_parts.py", line 56, in test_publish
self.assertEqual(case_expected, self.format_output(parts))
AssertionError: {'fra[51 chars]e>cat <span class="s"><<EOF\nHello World[24 chars]>\n'} != {'fra[51 chars]e>cat<span class="w"> </span><span class="s">&[47 chars]>\n'}
- {'fragment': '<pre class="code shell literal-block"><code>cat <span '
? -
+ {'fragment': '<pre class="code shell literal-block"><code>cat<span class="w"> '
? +++++++++++
- 'class="s"><<EOF\n'
+ '</span><span class="s"><<EOF\n'
? +++++++++++++
'Hello World\n'
'EOF</span></code></pre>\n'}
======================================================================
FAIL: test_publish (test_writers.test_html5_polyglot_parts.Html5WriterPublishPartsTestCase) (id="totest['syntax_highlight'][1]")
----------------------------------------------------------------------
Traceback (most recent call last):
File "/tmp/docutils/test/test_writers/test_html5_polyglot_parts.py", line 56, in test_publish
self.assertEqual(case_expected, self.format_output(parts))
AssertionError: {'fra[30 chars]">cat <span class="s"><<EOF Hello World [20 chars]>\n'} != {'fra[30 chars]">cat<span class="w"> </span><span class="s">&[43 chars]>\n'}
- {'fragment': '<p><code class="shell">cat <span class="s"><<EOF Hello '
? - ^ ^^^^^^^^^^^^^^^^^
+ {'fragment': '<p><code class="shell">cat<span class="w"> </span><span '
? ^ ^^^^^^^^^^^^^
- 'World EOF</span></code></p>\n'}
+ 'class="s"><<EOF Hello World EOF</span></code></p>\n'}
? ++++++++++++++++++++++++++++
```
Bisected it down to:
```
commit c6abd4cdee5323630fd7ac12b425bfc3f6d23075
Author: milde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>
Date: Fri Nov 10 13:12:16 2023 +0000
Simplify "HTML5 parts test", add test case for bug #476.
git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk/docutils@9470 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
test/test_writers/test_html5_polyglot_parts.py | 286 ++++---------------------
1 file changed, 47 insertions(+), 239 deletions(-)
```
I can reproduce with Python 3.10.14, 3.11.9, 3.12.3; Pillow 10.3.0, Pygments 2.17.2.
---
Sent from sourceforge.net because doc...@li... is subscribed to https://sourceforge.net/p/docutils/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list. |