Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4abab92

Browse files
committed
Mark test_conditional_includes_from_git_dir xfail on Windows
As noted, the second of the config._included_paths() assertionsfails, which is in the "Ensure that config is included if path ismatching git_dir" sub-case.It is returning 0 on Windows. THe GitConfigParser._has_includesfunction returns the expression: self._merge_includes and len(self._included_paths())Since _merge_includes is a bool, it appears the first branch of the"and" is True, but then _included_paths returns an empty list.
1 parent42a3d74 commit4abab92

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

‎test/test_config.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,15 @@
66
importglob
77
importio
88
importos
9+
importos.pathasosp
910
fromunittestimportmock
1011

12+
importpytest
13+
1114
fromgitimportGitConfigParser
1215
fromgit.configimport_OMD,cp
13-
fromtest.libimport (
14-
TestCase,
15-
fixture_path,
16-
SkipTest,
17-
)
18-
fromtest.libimportwith_rw_directory
19-
20-
importos.pathasosp
2116
fromgit.utilimportrmfile
17+
fromtest.libimportSkipTest,TestCase,fixture_path,with_rw_directory
2218

2319

2420
_tc_lock_fpaths=osp.join(osp.dirname(__file__),"fixtures/*.lock")
@@ -239,6 +235,11 @@ def check_test_value(cr, value):
239235
withGitConfigParser(fpa,read_only=True)ascr:
240236
check_test_value(cr,tv)
241237

238+
@pytest.mark.xfail(
239+
os.name=="nt",
240+
reason='Second config._has_includes() assertion fails (for "config is included if path is matching git_dir")',
241+
raises=AssertionError,
242+
)
242243
@with_rw_directory
243244
deftest_conditional_includes_from_git_dir(self,rw_dir):
244245
# Initiate repository path.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp