Преглед на файлове

Add unit test for crash-on-empty-walk

Benjamin Pollack преди 12 години
родител
ревизия
3b3c8febf5
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. 4 0
      dulwich/tests/test_walk.py

+ 4 - 0
dulwich/tests/test_walk.py

@@ -410,3 +410,7 @@ class WalkerTest(TestCase):
         # Ensure that c1..y4 get excluded even though they're popped from the
         # priority queue long before y5.
         self.assertWalkYields([m6, x2], [m6.id], exclude=[y5.id])
+
+    def test_empty_walk(self):
+        c1, c2, c3 = self.make_linear_commits(3)
+        self.assertWalkYields([], [c3.id], exclude=[c3.id])