allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tvansteenbu...@apache.org
Subject [08/50] git commit: [#3154] ticket:394 Fix test
Date Mon, 26 Aug 2013 14:00:47 GMT
[#3154] ticket:394 Fix test


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

Branch: refs/heads/tv/6595
Commit: f0d671e4fc8ecaf7bc4f44b78dcd506a4b6fbb96
Parents: 0b4c11b
Author: Igor Bondarenko <jetmind2@gmail.com>
Authored: Tue Jul 23 14:19:03 2013 +0000
Committer: Dave Brondsema <dbrondsema@slashdotmedia.com>
Committed: Thu Aug 22 20:04:41 2013 +0000

----------------------------------------------------------------------
 ForgeLink/forgelink/tests/test_app.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/f0d671e4/ForgeLink/forgelink/tests/test_app.py
----------------------------------------------------------------------
diff --git a/ForgeLink/forgelink/tests/test_app.py b/ForgeLink/forgelink/tests/test_app.py
index 2176b10..3290aa2 100644
--- a/ForgeLink/forgelink/tests/test_app.py
+++ b/ForgeLink/forgelink/tests/test_app.py
@@ -18,8 +18,11 @@
 import tempfile
 import json
 
+from nose.tools import assert_equal
+
 from allura.tests import decorators as td
 from allura import model as M
+from allura.lib import helpers as h
 from alluratest.controller import setup_basic_test
 
 
@@ -32,8 +35,9 @@ class TestBulkExport(object):
     def test_bulk_export(self):
         self.project = M.Project.query.get(shortname='test')
         self.link = self.project.app_instance('link')
+        h.set_context(self.project._id, app_config_id=self.link.config._id)
         self.link.config.options['url'] = 'http://sf.net'
         f = tempfile.TemporaryFile()
         self.link.bulk_export(f)
         f.seek(0)
-        assert json.loads(f.read())['url']=='http://sf.net'
\ No newline at end of file
+        assert_equal(json.loads(f.read())['url'], 'http://sf.net')


Mime
View raw message