Test failure with pygments 2.15
ogayot opened this issue · comments
Olivier Gayot commented
Hello,
The test suite fails against pygments 2.15:
Traceback (most recent call last):
File "/home/olivier/dev/canonical/ansible-pygments/tests/lexer_test.py", line 131, in <module>
test_ansible_output_lexer()
File "/home/olivier/dev/canonical/ansible-pygments/tests/lexer_test.py", line 78, in test_ansible_output_lexer
assert result == R"""<div class="highlight"><pre><span></span><span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">windows</span><span class="p">]</span> <span class="p">=></span> <span class="p">{</span>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError
Here is the diff of the output:
--- pygments-2.14.html 2023-05-11 18:25:10.635761541 +0200
+++ pygments-2.15.html 2023-05-11 18:31:31.421693061 +0200
@@ -8,7 +8,7 @@
<span class="p">}</span>
<span class="k">TASK</span> <span class="p">[</span><span class="l">paused</span><span class="p">]</span> <span class="nv">************************************************************************************************************************************</span>
-<span class="w">Sunday 11 November 2018 20:16:48 +0100 (0:00:00.041) 0:07:59.637 *******</span>
+Sunday 11 November 2018 20:16:48 +0100 (0:00:00.041) 0:07:59.637 *******
<span class="gd">--- before</span>
<span class="gi">+++ after</span>
<span class="gu">@@ -1,5 +1,5 @@</span>
@@ -20,12 +20,12 @@
<span class="gi">+ "paused": true,</span>
<span class="gi">+ "running": true</span>
<span class="w"> </span>}
-<span class="w">\ No newline at end of file</span>
+\ No newline at end of file
<span class="k">changed</span><span class="p">:</span> <span class="p">[</span><span class="nv">localhost</span><span class="p">]</span>
<span class="k">TASK</span> <span class="p">[</span><span class="l">volumes (more volumes)</span><span class="p">]</span> <span class="nv">********************************************************************************************************************</span>
-<span class="w">Sunday 11 November 2018 20:19:25 +0100 (0:00:00.607) 0:10:36.974 *******</span>
+Sunday 11 November 2018 20:19:25 +0100 (0:00:00.607) 0:10:36.974 *******
<span class="gd">--- before</span>
<span class="gi">+++ after</span>
<span class="gu">@@ -1,11 +1,11 @@</span>
@@ -44,7 +44,7 @@
<span class="w"> </span> },
<span class="w"> </span> "running": true
<span class="w"> </span>}
-<span class="w">\ No newline at end of file</span>
+\ No newline at end of file
<span class="k">changed</span><span class="p">:</span> <span class="p">[</span><span class="nv">localhost</span><span class="p">]</span>
</pre></div>
According to git bisect, the ansible-pygments test failure started with pygments/pygments@4159c08
Does it sound safe to modify the tests to remove the <span class="w">
around the date and "\ No newline at end of file"? Or does it sounds like an actual regression?
Thanks!
Olivier
Olivier Gayot commented
@webknjaz I appreciate the quick work! Thanks for that. I confirm that the issue is fixed.
Best regards,
Olivier