summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/python-tests.yml2
-rw-r--r--testing/test_file_finder.py2
-rw-r--r--testing/test_git.py9
3 files changed, 11 insertions, 2 deletions
diff --git a/.github/workflows/python-tests.yml b/.github/workflows/python-tests.yml
index d8f8ead..ca8df3f 100644
--- a/.github/workflows/python-tests.yml
+++ b/.github/workflows/python-tests.yml
@@ -19,8 +19,6 @@ jobs:
os: [windows-latest, ubuntu-latest] #, macos-latest]
exclude:
- os: windows-latest
- python_version: "2.7"
- - os: windows-latest
python_version: "pypy2"
include:
- os: ubuntu-latest
diff --git a/testing/test_file_finder.py b/testing/test_file_finder.py
index a6e3d70..463d3d4 100644
--- a/testing/test_file_finder.py
+++ b/testing/test_file_finder.py
@@ -9,6 +9,8 @@ from setuptools_scm.integration import find_files
@pytest.fixture(params=["git", "hg"])
def inwd(request, wd, monkeypatch):
if request.param == "git":
+ if sys.platform == "win32" and sys.version_info[0] < 3:
+ pytest.skip("Long/short path names supported on Windows Python 2.7")
try:
wd("git init")
except OSError:
diff --git a/testing/test_git.py b/testing/test_git.py
index e485fc7..e92d19a 100644
--- a/testing/test_git.py
+++ b/testing/test_git.py
@@ -10,6 +10,12 @@ from setuptools_scm.file_finder_git import git_find_files
import warnings
+skip_if_win_27 = pytest.mark.skipif(
+ sys.platform == "win32" and sys.version_info[0] < 3,
+ reason="Not supported on Windows + Python 2.7",
+)
+
+
with warnings.catch_warnings():
warnings.filterwarnings("ignore")
if not has_command("git"):
@@ -186,6 +192,7 @@ def test_alphanumeric_tags_match(wd):
assert wd.version.startswith("0.1.dev1+g")
+@skip_if_win_27
def test_git_archive_export_ignore(wd, monkeypatch):
wd.write("test1.txt", "test")
wd.write("test2.txt", "test")
@@ -201,6 +208,7 @@ def test_git_archive_export_ignore(wd, monkeypatch):
assert integration.find_files(".") == [opj(".", "test1.txt")]
+@skip_if_win_27
@pytest.mark.issue(228)
def test_git_archive_subdirectory(wd, monkeypatch):
wd("mkdir foobar")
@@ -211,6 +219,7 @@ def test_git_archive_subdirectory(wd, monkeypatch):
assert integration.find_files(".") == [opj(".", "foobar", "test1.txt")]
+@skip_if_win_27
@pytest.mark.issue(251)
def test_git_archive_run_from_subdirectory(wd, monkeypatch):
wd("mkdir foobar")