You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by br...@apache.org on 2017/03/29 21:38:42 UTC

allura git commit: Change the ForgeUserStats tests' git repos to be unique from each other so they can be run in parallel safely

Repository: allura
Updated Branches:
  refs/heads/master 138129a3c -> ec1863778


Change the ForgeUserStats tests' git repos to be unique from each other so they can be run in parallel safely


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

Branch: refs/heads/master
Commit: ec1863778aa74df95f21e153809f501402f4c86a
Parents: 138129a
Author: Dave Brondsema <da...@brondsema.net>
Authored: Wed Mar 29 14:25:38 2017 -0400
Committer: Dave Brondsema <da...@brondsema.net>
Committed: Wed Mar 29 14:25:38 2017 -0400

----------------------------------------------------------------------
 ForgeUserStats/forgeuserstats/tests/test_model.py |  4 +---
 ForgeUserStats/forgeuserstats/tests/test_stats.py | 12 ++----------
 2 files changed, 3 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/ec186377/ForgeUserStats/forgeuserstats/tests/test_model.py
----------------------------------------------------------------------
diff --git a/ForgeUserStats/forgeuserstats/tests/test_model.py b/ForgeUserStats/forgeuserstats/tests/test_model.py
index 5076347..3804063 100644
--- a/ForgeUserStats/forgeuserstats/tests/test_model.py
+++ b/ForgeUserStats/forgeuserstats/tests/test_model.py
@@ -33,9 +33,7 @@ from forgeuserstats.model import stats as USM
 
 # important to be distinct from 'test' which ForgeGit uses, so that the
 # tests can run in parallel and not clobber each other
-test_project_with_repo = 'test2'
-with_git = td.with_tool(test_project_with_repo, 'Git',
-                        'src-git', 'Git', type='git')
+with_git = td.with_tool('test', 'Git', 'git-userstats-model', 'Git', type='git')
 
 
 class TestUserStats(unittest.TestCase):

http://git-wip-us.apache.org/repos/asf/allura/blob/ec186377/ForgeUserStats/forgeuserstats/tests/test_stats.py
----------------------------------------------------------------------
diff --git a/ForgeUserStats/forgeuserstats/tests/test_stats.py b/ForgeUserStats/forgeuserstats/tests/test_stats.py
index ade4a33..ff76087 100644
--- a/ForgeUserStats/forgeuserstats/tests/test_stats.py
+++ b/ForgeUserStats/forgeuserstats/tests/test_stats.py
@@ -29,13 +29,6 @@ from allura import model as M
 from forgetracker import model as TM
 
 
-# important to be distinct from 'test' which ForgeGit uses, so that the
-# tests can run in parallel and not clobber each other
-test_project_with_repo = 'test2'
-with_git = td.with_tool(test_project_with_repo, 'Git',
-                        'src-git', 'Git', type='git')
-
-
 class TestStats(TestController):
 
     def setUp(self):
@@ -203,12 +196,11 @@ class TestGitCommit(TestController, unittest.TestCase):
         addr.confirmed = True
         self.setup_with_tools()
 
-    @with_git
+    @td.with_tool('test', 'Git', 'git-userstats-stats', 'Git', type='git')
     @td.with_wiki
     def setup_with_tools(self):
         setup_global_objects()
-        h.set_context(test_project_with_repo, 'src-git',
-                      neighborhood='Projects')
+        h.set_context('test', 'git-userstats-stats', neighborhood='Projects')
         repo_dir = pkg_resources.resource_filename(
             'forgeuserstats', 'tests/data')
         c.app.repo.fs_path = repo_dir