Selaa lähdekoodia

Windows doesn't have "posix" module, use "os" instead. Otherwise the test suite fails to run even a single test.

Risto Kankkunen 13 vuotta sitten
vanhempi
commit
d90678b396
1 muutettua tiedostoa jossa 2 lisäystä ja 3 poistoa
  1. 2 3
      dulwich/tests/test_index.py

+ 2 - 3
dulwich/tests/test_index.py

@@ -23,7 +23,6 @@ from cStringIO import (
     StringIO,
     )
 import os
-import posix
 import shutil
 import stat
 import struct
@@ -176,7 +175,7 @@ class WriteCacheTimeTests(TestCase):
 class IndexEntryFromStatTests(TestCase):
 
     def test_simple(self):
-        st = posix.stat_result((16877, 131078, 64769L,
+        st = os.stat_result((16877, 131078, 64769L,
                 154, 1000, 1000, 12288,
                 1323629595, 1324180496, 1324180496))
         entry = index_entry_from_stat(st, "22" * 20, 0)
@@ -193,7 +192,7 @@ class IndexEntryFromStatTests(TestCase):
             0))
 
     def test_override_mode(self):
-        st = posix.stat_result((stat.S_IFREG + 0644, 131078, 64769L,
+        st = os.stat_result((stat.S_IFREG + 0644, 131078, 64769L,
                 154, 1000, 1000, 12288,
                 1323629595, 1324180496, 1324180496))
         entry = index_entry_from_stat(st, "22" * 20, 0,