comparison rhodecode/tests/functional/test_summary.py @ 1895:b7adbd5456c2 beta

test fixes for latest changes
author Marcin Kuzminski <marcin@python-works.com>
date Fri, 13 Jan 2012 06:38:36 +0200
parents cf51bbfb120e
children 82a88013a3fd 402a96fcfa22
comparison
equal deleted inserted replaced
1894:0cbc3fb540b0 1895:b7adbd5456c2
11 response = self.app.get(url(controller='summary', 11 response = self.app.get(url(controller='summary',
12 action='index', 12 action='index',
13 repo_name=HG_REPO)) 13 repo_name=HG_REPO))
14 14
15 #repo type 15 #repo type
16 response.mustcontain("""<img style="margin-bottom:2px" class="icon" """ 16 response.mustcontain(
17 """title="Mercurial repository" alt="Mercurial """ 17 """<img style="margin-bottom:2px" class="icon" """
18 """repository" src="/images/icons/hgicon.png"/>""") 18 """title="Mercurial repository" alt="Mercurial """
19 response.mustcontain("""<img style="margin-bottom:2px" class="icon" """ 19 """repository" src="/images/icons/hgicon.png"/>"""
20 """title="public repository" alt="public """ 20 )
21 """repository" src="/images/icons/lock_open.png"/>""") 21 response.mustcontain(
22 """<img style="margin-bottom:2px" class="icon" """
23 """title="public repository" alt="public """
24 """repository" src="/images/icons/lock_open.png"/>"""
25 )
22 26
23 #codes stats 27 #codes stats
24 self._enable_stats() 28 self._enable_stats()
25 29
26 invalidate_cache('get_repo_cached_%s' % HG_REPO) 30 invalidate_cache('get_repo_cached_%s' % HG_REPO)
27 response = self.app.get(url(controller='summary', action='index', 31 response = self.app.get(url(controller='summary', action='index',
28 repo_name=HG_REPO)) 32 repo_name=HG_REPO))
29 33 response.mustcontain(
30 self.assertTrue("""var data = {"py": {"count": 42, "desc": """ 34 """var data = [["py", {"count": 42, "desc": ["Python"]}], """
31 """["Python"]}, "rst": {"count": 11, "desc": """ 35 """["rst", {"count": 11, "desc": ["Rst"]}], """
32 """["Rst"]}, "sh": {"count": 2, "desc": ["Bash"]}, """ 36 """["sh", {"count": 2, "desc": ["Bash"]}], """
33 """"makefile": {"count": 1, "desc": ["Makefile", """ 37 """["makefile", {"count": 1, "desc": ["Makefile", "Makefile"]}],"""
34 """"Makefile"]}, "cfg": {"count": 1, "desc": ["Ini"]},""" 38 """ ["cfg", {"count": 1, "desc": ["Ini"]}], """
35 """ "css": {"count": 1, "desc": ["Css"]}, "bat": """ 39 """["css", {"count": 1, "desc": ["Css"]}], """
36 """{"count": 1, "desc": ["Batch"]}};""" 40 """["bat", {"count": 1, "desc": ["Batch"]}]];"""
37 in response.body) 41 )
38 42
39 # clone url... 43 # clone url...
40 response.mustcontain("""<input style="width:80%;margin-left:105px" type="text" id="clone_url" readonly="readonly" value="http://test_admin@localhost:80/vcs_test_hg"/>""") 44 response.mustcontain("""<input style="width:80%;margin-left:105px" type="text" id="clone_url" readonly="readonly" value="http://test_admin@localhost:80/vcs_test_hg"/>""")
41 response.mustcontain("""<input style="display:none;width:80%;margin-left:105px" type="text" id="clone_url_id" readonly="readonly" value="http://test_admin@localhost:80/_1"/>""") 45 response.mustcontain("""<input style="display:none;width:80%;margin-left:105px" type="text" id="clone_url_id" readonly="readonly" value="http://test_admin@localhost:80/_1"/>""")
42 46