golang: test: Fix for Pytest < 7
In 74a9838c (golang: tests: Fix for Pytest ≥ 7.4) I fixed test_defer_excchain_dump_pytest for Pytest ≥ 7.4 but missed that pytest.version_tuple is not available for Pytest < 7.0(*) which started to lead to pygolang test failures on py3 under SlapOS becuase there we are still using pytest 4.6.11 : _______________________ test_defer_excchain_dump_pytest ________________________ def test_defer_excchain_dump_pytest(): # pytest 7.4 also changed traceback output format # similarly to ipython we do not need to test it becase we activate # pytest-related patch only on py2 for which latest pytest version is 4.6.11 . import pytest > if six.PY3 and pytest.version_tuple >= (7,4): E AttributeError: module 'pytest' has no attribute 'version_tuple' https://stack.nexedi.com/test_result_module/20240920-666C5CF1/3 -> Fix that by checking pytest.version_tuple more carefully. (*) see https://docs.pytest.org/en/stable/reference/reference.html#pytest-version-tuple /reviewed-by @jerome /reviewed-on !29
Status | Job ID | Name | Coverage | ||||||
---|---|---|---|---|---|---|---|---|---|
External | |||||||||
passed |
#715291
external
|
Pygolang.UnitTest-Master.Python2 |
00:01:43
|
||||||
passed |
#715208
external
|
Pygolang.UnitTest-Master.Python3 |
00:02:18
|
||||||
passed |
#714641
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:46
|
||||||
passed |
#714983
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:32
|
||||||
passed |
#715040
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:52
|
||||||
passed |
#715207
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:39
|
||||||
passed |
#715249
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:47
|
||||||
passed |
#714829
external
retried
|
Pygolang.UnitTest-Master.Python2 |
00:01:27
|
||||||
passed |
#714674
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:28
|
||||||
passed |
#714984
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:10
|
||||||
passed |
#714842
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:01:55
|
||||||
passed |
#715035
external
retried
|
Pygolang.UnitTest-Master.Python3 |
00:02:27
|
||||||