ソースを参照

Test for `fallback_app` (236052093a22fabbb52657f8d36bd02642e5e288)

Jonas Haag 12 年 前
コミット
95b6f9b51c
1 ファイル変更7 行追加0 行削除
  1. 7 0
      dulwich/tests/test_web.py

+ 7 - 0
dulwich/tests/test_web.py

@@ -443,6 +443,13 @@ class HTTPGitApplicationTestCase(TestCase):
         self._add_handler(self._app)
         self.assertEqual('output', self._app(self._environ, None))
 
+    def test_fallback_app(self):
+        def test_app(environ, start_response):
+            return 'output'
+
+        app = HTTPGitApplication('backend', fallback_app=test_app)
+        self.assertEqual('output', app(self._environ, None))
+
 
 class GunzipTestCase(HTTPGitApplicationTestCase):
     """TestCase for testing the GunzipFilter, ensuring the wsgi.input