You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by tv...@apache.org on 2013/12/13 06:08:22 UTC

[36/45] git commit: [#6830] Fix test to account for changed menu

[#6830] Fix test to account for changed menu

(The activity tool is no longer hidden.)

Signed-off-by: Tim Van Steenburgh <tv...@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/92085995
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/92085995
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/92085995

Branch: refs/heads/tv/6942
Commit: 920859956083a7741e7f67f89b3a18455de2907d
Parents: 4aeceac
Author: Tim Van Steenburgh <tv...@gmail.com>
Authored: Thu Dec 12 20:08:43 2013 +0000
Committer: Tim Van Steenburgh <tv...@gmail.com>
Committed: Thu Dec 12 20:08:43 2013 +0000

----------------------------------------------------------------------
 Allura/allura/tests/functional/test_home.py | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/92085995/Allura/allura/tests/functional/test_home.py
----------------------------------------------------------------------
diff --git a/Allura/allura/tests/functional/test_home.py b/Allura/allura/tests/functional/test_home.py
index f57107f..1a5bb57 100644
--- a/Allura/allura/tests/functional/test_home.py
+++ b/Allura/allura/tests/functional/test_home.py
@@ -50,9 +50,10 @@ class TestProjectHome(TestController):
 
         response = self.app.get('/p/test/_nav.json')
         menu = response.json['menu']
-        assert_equal(len(menu[1]['children']), 2)
-        assert {u'url': u'/p/test/wiki/', u'name': u'Wiki', u'icon': u'tool-wiki', 'tool_name': 'wiki'} in menu[1]['children'], menu[1]['children']
-        assert {u'url': u'/p/test/wiki2/', u'name': u'wiki2', u'icon': u'tool-wiki', 'tool_name': 'wiki'} in menu[1]['children'], menu[1]['children']
+        wikis = menu[-2]['children']
+        assert_equal(len(wikis), 2)
+        assert {u'url': u'/p/test/wiki/', u'name': u'Wiki', u'icon': u'tool-wiki', 'tool_name': 'wiki'} in wikis, wikis
+        assert {u'url': u'/p/test/wiki2/', u'name': u'wiki2', u'icon': u'tool-wiki', 'tool_name': 'wiki'} in wikis, wikis
 
     @td.with_wiki
     def test_project_group_nav_more_than_ten(self):