diff options
author | Marcin Kuzminski <marcin@python-works.com> | 2012-09-07 18:00:31 +0200 |
---|---|---|
committer | Marcin Kuzminski <marcin@python-works.com> | 2012-09-07 18:00:31 +0200 |
commit | 7fbb9c02356581dc841447cb0312c1da44a6d40e (patch) | |
tree | e03057bc2f8f4cbf71205b99118b7c9696a19069 /rhodecode/tests/functional | |
parent | ff73cf894445fa64e80bb0139292abe4cdcf91fa (diff) |
fixed issue #559 fixed bug in routing that mapped repo names with <name>_<num> in name as
if it was a request to url by repository ID
--HG--
branch : beta
Diffstat (limited to 'rhodecode/tests/functional')
-rw-r--r-- | rhodecode/tests/functional/test_summary.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/rhodecode/tests/functional/test_summary.py b/rhodecode/tests/functional/test_summary.py index 4d270ddc..3dbeb1c8 100644 --- a/rhodecode/tests/functional/test_summary.py +++ b/rhodecode/tests/functional/test_summary.py @@ -1,6 +1,9 @@ from rhodecode.tests import * from rhodecode.model.db import Repository from rhodecode.lib.utils import invalidate_cache +from rhodecode.model.repo import RepoModel +from rhodecode.tests.models.common import _make_repo +from rhodecode.model.meta import Session class TestSummaryController(TestController): @@ -82,6 +85,20 @@ class TestSummaryController(TestController): """title="public repository" alt="public """ """repository" src="/images/icons/lock_open.png"/>""") + def test_index_by_repo_having_id_path_in_name_hg(self): + self.log_user() + _make_repo(name='repo_1') + Session().commit() + response = self.app.get(url(controller='summary', + action='index', + repo_name='repo_1')) + + try: + response.mustcontain("""repo_1""") + finally: + RepoModel().delete(Repository.get_by_repo_name('repo_1')) + Session().commit() + def test_index_by_id_git(self): self.log_user() ID = Repository.get_by_repo_name(GIT_REPO).repo_id |