Skip to content

Commit

Permalink
mark path case sensitive tests as xfail for win32
Browse files Browse the repository at this point in the history
  • Loading branch information
abn committed Apr 23, 2020
1 parent 6f263bb commit 54917c8
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions poetry/core/utils/_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
PY34 = sys.version_info >= (3, 4)
PY35 = sys.version_info >= (3, 5)
PY36 = sys.version_info >= (3, 6)
PY37 = sys.version_info >= (3, 7)

WINDOWS = sys.platform == "win32"

Expand Down
13 changes: 13 additions & 0 deletions tests/masonry/builders/test_builder.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
# -*- coding: utf-8 -*-
import sys

from email.parser import Parser

import pytest

from poetry.core.factory import Factory
from poetry.core.masonry.builders.builder import Builder
from poetry.core.utils._compat import PY37
from poetry.core.utils._compat import Path


Expand All @@ -17,6 +22,10 @@ def test_builder_find_excluded_files(mocker):
assert builder.find_excluded_files() == {"my_package/sub_pkg1/extra_file.xml"}


@pytest.mark.xfail(
sys.platform == "win32" and not PY37,
reason="Windows is case insensitive for the most part",
)
def test_builder_find_case_sensitive_excluded_files(mocker):
p = mocker.patch("poetry.core.vcs.git.Git.get_ignored_files")
p.return_value = []
Expand All @@ -38,6 +47,10 @@ def test_builder_find_case_sensitive_excluded_files(mocker):
}


@pytest.mark.xfail(
sys.platform == "win32" and not PY37,
reason="Windows is case insensitive for the most part",
)
def test_builder_find_invalid_case_sensitive_excluded_files(mocker):
p = mocker.patch("poetry.core.vcs.git.Git.get_ignored_files")
p.return_value = []
Expand Down

0 comments on commit 54917c8

Please sign in to comment.