diff --git a/rhodecode/tests/functional/test_summary.py b/rhodecode/tests/functional/test_summary.py
--- a/rhodecode/tests/functional/test_summary.py
+++ b/rhodecode/tests/functional/test_summary.py
@@ -2,27 +2,27 @@ from rhodecode.tests import *
from rhodecode.model.db import Repository
from rhodecode.lib.utils import invalidate_cache
+
class TestSummaryController(TestController):
def test_index(self):
self.log_user()
+ ID = Repository.get_by_repo_name(HG_REPO).repo_id
response = self.app.get(url(controller='summary',
- action='index', repo_name=HG_REPO))
+ action='index',
+ repo_name=HG_REPO))
#repo type
- self.assertTrue("""
"""
- in response.body)
- self.assertTrue("""
""")
+ response.mustcontain("""
"""
- in response.body)
+ """repository" src="/images/icons/lock_open.png"/>""")
#codes stats
self._enable_stats()
-
invalidate_cache('get_repo_cached_%s' % HG_REPO)
response = self.app.get(url(controller='summary', action='index',
repo_name=HG_REPO))
@@ -37,8 +37,23 @@ class TestSummaryController(TestControll
in response.body)
# clone url...
- self.assertTrue("""""" % HG_REPO in response.body)
+ response.mustcontain("""""")
+ response.mustcontain("""""")
+ def test_index_by_id(self):
+ self.log_user()
+ ID = Repository.get_by_repo_name(HG_REPO).repo_id
+ response = self.app.get(url(controller='summary',
+ action='index',
+ repo_name='_%s' % ID))
+
+ #repo type
+ response.mustcontain("""
""")
+ response.mustcontain("""
""")
def _enable_stats(self):
r = Repository.get_by_repo_name(HG_REPO)