allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject allura git commit: [#5194] no notification of default wiki Home page, when installing a wiki tool
Date Tue, 12 Jul 2016 20:31:36 GMT
Repository: allura
Updated Branches:
  refs/heads/db/5194 [created] 261f57987


[#5194] no notification of default wiki Home page, when installing a wiki tool


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

Branch: refs/heads/db/5194
Commit: 261f579873e49f4820aeef478a386c575840dcc0
Parents: ac793fe
Author: Dave Brondsema <dave@brondsema.net>
Authored: Tue Jul 12 16:31:22 2016 -0400
Committer: Dave Brondsema <dave@brondsema.net>
Committed: Tue Jul 12 16:31:22 2016 -0400

----------------------------------------------------------------------
 Allura/allura/tests/model/test_notification.py | 2 --
 ForgeWiki/forgewiki/wiki_main.py               | 6 +++---
 2 files changed, 3 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/261f5798/Allura/allura/tests/model/test_notification.py
----------------------------------------------------------------------
diff --git a/Allura/allura/tests/model/test_notification.py b/Allura/allura/tests/model/test_notification.py
index 869a704..6fffda0 100644
--- a/Allura/allura/tests/model/test_notification.py
+++ b/Allura/allura/tests/model/test_notification.py
@@ -206,8 +206,6 @@ class TestPostNotifications(unittest.TestCase):
         self._post_notification()
         M.MonQTask.run_ready()
         ThreadLocalORMSession.flush_all()
-        M.MonQTask.run_ready()
-        ThreadLocalORMSession.flush_all()
         assert M.Mailbox.query.find().count() == 1
         mbox = M.Mailbox.query.get()
         assert len(mbox.queue) == 1

http://git-wip-us.apache.org/repos/asf/allura/blob/261f5798/ForgeWiki/forgewiki/wiki_main.py
----------------------------------------------------------------------
diff --git a/ForgeWiki/forgewiki/wiki_main.py b/ForgeWiki/forgewiki/wiki_main.py
index 60a85d4..ace38b6 100644
--- a/ForgeWiki/forgewiki/wiki_main.py
+++ b/ForgeWiki/forgewiki/wiki_main.py
@@ -320,13 +320,13 @@ The wiki uses [Markdown](%s) syntax.
         ]
         root_page_name = self.default_root_page_name
         WM.Globals(app_config_id=c.app.config._id, root=root_page_name)
-        self.upsert_root(root_page_name)
+        self.upsert_root(root_page_name, notify=False)
 
-    def upsert_root(self, new_root):
+    def upsert_root(self, new_root, notify=True):
         p = WM.Page.query.get(app_config_id=self.config._id,
                               title=new_root, deleted=False)
         if p is None:
-            with h.push_config(c, app=self):
+            with h.push_config(c, app=self), h.notifications_disabled(c.project, disabled=not
notify):
                 p = WM.Page.upsert(new_root)
                 p.viewable_by = ['all']
                 p.text = self.default_root_page_text()


Mime
View raw message