Mark test_repo_last_mtime xfail on Python < 3.5 (#30696)

This commit is contained in:
Massimiliano Culpo 2022-05-17 12:45:52 +02:00 committed by GitHub
parent d7d0c892d8
commit f454a683b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,8 +2,8 @@
# Spack Project Developers. See the top-level COPYRIGHT file for details. # Spack Project Developers. See the top-level COPYRIGHT file for details.
# #
# SPDX-License-Identifier: (Apache-2.0 OR MIT) # SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os import os
import sys
import pytest import pytest
@ -59,6 +59,9 @@ def test_repo_anonymous_pkg(mutable_mock_repo):
@pytest.mark.maybeslow @pytest.mark.maybeslow
@pytest.mark.skipif(
sys.version_info < (3, 5), reason="Test started failing spuriously on Python 2.7"
)
def test_repo_last_mtime(): def test_repo_last_mtime():
latest_mtime = max(os.path.getmtime(p.module.__file__) latest_mtime = max(os.path.getmtime(p.module.__file__)
for p in spack.repo.path.all_packages()) for p in spack.repo.path.all_packages())