You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by di...@apache.org on 2022/09/15 13:46:36 UTC

[allura] 01/05: fixup! all trivial failures resolved for ./Allura, only legit failures remain

This is an automated email from the ASF dual-hosted git repository.

dill0wn pushed a commit to branch dw/8455
in repository https://gitbox.apache.org/repos/asf/allura.git

commit 422a25a2e41666ca3f77660903b2ad5060c6a590
Author: Dillon Walls <di...@slashdotmedia.com>
AuthorDate: Mon Sep 12 15:11:09 2022 +0000

    fixup! all trivial failures resolved for ./Allura, only legit failures remain
---
 Allura/allura/tests/test_globals.py | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/Allura/allura/tests/test_globals.py b/Allura/allura/tests/test_globals.py
index f75f2d268..4d4b3b592 100644
--- a/Allura/allura/tests/test_globals.py
+++ b/Allura/allura/tests/test_globals.py
@@ -48,11 +48,17 @@ from forgewiki import model as WM
 from forgeblog import model as BM
 
 
+def setup_module(module):
+    setup_basic_test()
+    setup_unit_test()
+
+
 def squish_spaces(text):
     # \s is whitespace
     # \xa0 is &nbsp; in unicode form
     return re.sub(r'[\s\xa0]+', ' ', text)
 
+
 def get_project_names(r):
     """
     Extracts a list of project names from a wiki page HTML.
@@ -75,13 +81,10 @@ def get_projects_property_in_the_same_order(names, prop):
     return [projects_dict[name] for name in names]
 
 
-
 @with_nose_compatibility
 class Test():
 
     def setup_method(self, method):
-        setup_basic_test()
-        setup_unit_test()
         setup_global_objects()
 
     @td.with_wiki
@@ -514,7 +517,6 @@ class Test():
             '1. first item<br/>\n'
             '2. second item</p></div>')
 
-
     def test_markdown_autolink(self):
         tgt = 'http://everything2.com/?node=nate+oostendorp'
         s = g.markdown.convert('This is %s' % tgt)
@@ -759,7 +761,6 @@ class Test():
             assert '<div class="markdown_content"><p>test post2</p></div>' in r
             assert 'by <em>Test Admin</em>' in r
 
-
     def test_project_screenshots_macro(self):
         with h.push_context('test', neighborhood='Projects'):
             M.ProjectFile(project_id=c.project._id, category='screenshot', caption='caption', filename='test_file.jpg')
@@ -770,6 +771,7 @@ class Test():
             assert 'href="/p/test/screenshot/test_file.jpg"' in r
             assert 'src="/p/test/screenshot/test_file.jpg/thumb"' in r
 
+
 @with_nose_compatibility
 class TestCachedMarkdown(unittest.TestCase):