Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Douglas
erp5
Commits
96b70605
Commit
96b70605
authored
May 10, 2011
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
runUnitTest: distribute activities automatically if there is only 1 node and no test to run
parent
a303a379
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
2 deletions
+6
-2
product/ERP5Type/tests/ProcessingNodeTestCase.py
product/ERP5Type/tests/ProcessingNodeTestCase.py
+2
-1
product/ERP5Type/tests/custom_zodb.py
product/ERP5Type/tests/custom_zodb.py
+4
-0
product/ERP5Type/tests/runUnitTest.py
product/ERP5Type/tests/runUnitTest.py
+0
-1
No files found.
product/ERP5Type/tests/ProcessingNodeTestCase.py
View file @
96b70605
...
...
@@ -239,7 +239,8 @@ class ProcessingNodeTestCase(backportUnittest.TestCase, ZopeTestCase.TestCase):
def
afterSetUp
(
self
):
"""Initialize a node that will only process activities"""
self
.
startZServer
()
self
.
_registerNode
(
distributing
=
0
,
processing
=
1
)
from
Zope2.custom_zodb
import
cluster
self
.
_registerNode
(
distributing
=
not
cluster
,
processing
=
1
)
transaction
.
commit
()
def
processing_node
(
self
):
...
...
product/ERP5Type/tests/custom_zodb.py
View file @
96b70605
...
...
@@ -115,6 +115,8 @@ def forkNodes():
break
node_pid_list
.
append
(
pid
)
cluster
=
True
if
neo_storage
:
if
load
or
save
or
zeo_client
:
raise
Exception
(
"--neo_storage conflicts with --load/save/zeo_client"
)
...
...
@@ -144,6 +146,8 @@ else:
elif
activity_node
is
not
None
:
# run ZEO server but no need to fork
zeo_server_pid
=
0
else
:
cluster
=
False
if
save
:
Storage
=
FileStorage
(
data_fs_path
)
...
...
product/ERP5Type/tests/runUnitTest.py
View file @
96b70605
...
...
@@ -487,7 +487,6 @@ def runUnitTestList(test_list, verbosity=1, debug=0, run_only=None):
TestRunner
=
backportUnittest
.
TextTestRunner
import
Lifetime
from
ZEO.ClientStorage
import
ClientStorage
from
Zope2.custom_zodb
import
Storage
,
save_mysql
,
\
node_pid_list
,
neo_cluster
,
zeo_server_pid
def
shutdown
(
signum
,
frame
,
signum_set
=
set
()):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment