Dulwich.io dulwich / 8fe9680
Fix some tests on Mac OS X. Jelmer Vernooń≥ 13 days ago
3 changed file(s) with 15 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
559559 # TODO(jelmer): record and return submodule paths
560560 else:
561561 obj = object_store[entry.sha]
562 st = build_file_from_blob(
563 obj, entry.mode, full_path, honor_filemode=honor_filemode)
562 try:
563 st = build_file_from_blob(
564 obj, entry.mode, full_path, honor_filemode=honor_filemode)
565 except OSError as e:
566 if e.errno == 92 and sys.platform == 'darwin':
567 # Our filename isn't supported by the platform :(
568 import warnings
569 warnings.warn(
570 'Unable to write ile %s: %s', full_path, e.strerror)
571 continue
572 else:
573 raise
574
564575 # Add file to index
565576 if not honor_filemode or S_ISGITLINK(entry.mode):
566577 # we can not use tuple slicing to build a new tuple,
4040 super(ShellHookTests, self).setUp()
4141 if os.name != 'posix':
4242 self.skipTest('shell hook tests requires POSIX shell')
43 self.assertTrue(os.path.exists('/bin/sh'))
4344
4445 def test_hook_pre_commit(self):
4546 repo_dir = os.path.join(tempfile.mkdtemp())
571571 self.assertEqual(expected_refs, self._repo.get_refs())
572572
573573 def test_cyrillic(self):
574 if sys.platform == 'win32':
574 if sys.platform in ('darwin', 'win32'):
575575 raise SkipTest(
576576 "filesystem encoding doesn't support arbitrary bytes")
577577 # reported in https://github.com/dulwich/dulwich/issues/608