You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by jo...@apache.org on 2013/05/23 03:43:49 UTC

[2/3] git commit: [#6046] ticket:350 Test 'Download Snapshot' link in repo subdirs

[#6046] ticket:350 Test 'Download Snapshot' link in repo subdirs


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

Branch: refs/heads/master
Commit: a5961a6edb651b366b8e27dc3e3a6724c06e85aa
Parents: 59f5867
Author: Igor Bondarenko <je...@gmail.com>
Authored: Fri May 10 08:32:30 2013 +0000
Committer: Cory Johns <cj...@slashdotmedia.com>
Committed: Thu May 23 01:18:17 2013 +0000

----------------------------------------------------------------------
 .../forgegit/tests/functional/test_controllers.py  |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/a5961a6e/ForgeGit/forgegit/tests/functional/test_controllers.py
----------------------------------------------------------------------
diff --git a/ForgeGit/forgegit/tests/functional/test_controllers.py b/ForgeGit/forgegit/tests/functional/test_controllers.py
index 0d253e1..787cef1 100644
--- a/ForgeGit/forgegit/tests/functional/test_controllers.py
+++ b/ForgeGit/forgegit/tests/functional/test_controllers.py
@@ -347,6 +347,14 @@ class TestRootController(_TestCase):
         r = self.app.get('/p/test/src-git/ci/master/tarball_status')
         assert '{"status": "ready"}' in r
 
+    def test_tarball_link_in_subdirs(self):
+        '''Go to repo subdir and check 'Download Snapshot' link'''
+        self.setup_testgit_index_repo()
+        r = self.app.get('/p/test/testgit-index/ci/master/tree/index/')
+        links = r.html.findAll('a')
+        download_link = [a for a in links if a.text == 'Download Snapshot'][0]
+        assert_equal(download_link.get('href'), '/p/test/testgit-index/ci/master/tarball')
+
 
 class TestRestController(_TestCase):