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
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Boxiang Sun
erp5
Commits
b74627b0
Commit
b74627b0
authored
Jun 07, 2013
by
Benjamin Blanc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update
parent
b8e0a1f3
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
48 deletions
+20
-48
erp5/tests/testERP5TestNode.py
erp5/tests/testERP5TestNode.py
+2
-0
erp5/util/testnode/ScalabilityTestRunner.py
erp5/util/testnode/ScalabilityTestRunner.py
+18
-30
erp5/util/testnode/SlapOSControler.py
erp5/util/testnode/SlapOSControler.py
+0
-1
erp5/util/testnode/UnitTestRunner.py
erp5/util/testnode/UnitTestRunner.py
+0
-17
No files found.
erp5/tests/testERP5TestNode.py
View file @
b74627b0
...
...
@@ -746,6 +746,8 @@ branch = foo
pass
def
test_scalability_10_prepareSlapOS
(
self
,
my_test_type
=
'ScalabilityTest'
):
# TODO : write own scalability test
# This case test may be dispensable on ScalabilityTest case
# so..
pass
def
test_scalability_11_run
(
self
,
my_test_type
=
'ScalabilityTest'
):
self
.
test_11_run
(
my_test_type
)
...
...
erp5/util/testnode/ScalabilityTestRunner.py
View file @
b74627b0
...
...
@@ -55,38 +55,28 @@ class ScalabilityTestRunner():
self
.
master_nodes
=
[]
# doesn't change during all the test
self
.
slave_nodes
=
[]
# doesn't change during all the test
# remaining_software_installation_grid contains at the begining
# all the softwares needed for this runner
# The grid looks like :
# { "COMP-1234" : ['http://soft1.cfg', 'https:///ipv6:00/soft2.cfg'],
# "COMP-4" : ['http://soft1.cfg', 'https:///ipv6:00/soft3.cfg'],
# "COMP-834" : ['http://soft4.cfg'],
# "COMP-90" : ['http://soft1.cfg', 'https:///ipv6:00/soft2.cfg'],
# }
# A thread is in charge of checking (by communication with slapOS Master)
# if softwares are correctly installed. If a software is correctly installed,
# the thread remove the software_url from the grid.
# The thread never stop his work until he is not killed.
# In an other hand, the runner (here) loop while the grid is not empty.
# When the grid is empty, it means that all softwares are installed, so
# the runner kills the thread and goes to the next procedure step.
# So, it also means that cluster_configuration, cluster_constraint
# and the list of availables/involved nodes (=> software repartition)
# have to be known to fill the grid.
self
.
remaining_software_installation_grid
=
{}
# Protection to prevent installation of softwares after checking
self
.
still_supply_to_request
=
True
def
checkingSoftwareGrid
(
self
):
self
.
still_supply_to_request
=
False
# Here we can
def
_prepareSlapOS
(
self
,
software_path
,
computer_guid
,
create_partition
=
0
):
# create_partition is kept for compatibility
"""
A proxy to supply : Install software a software on a specific node
"""
if
self
.
still_supply_to_request
==
True
:
if
not
(
computer_guid
in
self
.
remaining_software_installation_grid
):
# Add computer_guid to the grid if it isn't
self
.
remaining_software_installation_grid
[
computer_guid
]
=
[]
self
.
remaining_software_installation_grid
[
computer_guid
].
append
(
software_path
)
self
.
slapos_controler
.
supply
(
software_path
,
computer_guid
,
create_partition
)
# TODO : do something with slapOS Master to check if it's ok
# put it here ?
# TODO : change the line below
return
{
'status_code'
:
0
}
else
:
raise
ValueError
(
"Too late to supply now. ('self.still_supply_to_request' is False)"
)
def
prepareSlapOSForTestNode
(
self
,
test_node_slapos
=
None
):
"""
...
...
@@ -126,13 +116,11 @@ class ScalabilityTestRunner():
# TODO : define methods to check if involved nodes are okay etc..
# And if it's not end ans invalidate everything and retry/reloop
def
runTestSuite
(
self
,
node_test_suite
,
portal_url
,
log
=
None
):
# TODO : write code
SlapOSControler
.
createFolder
(
node_test_suite
.
test_suite_directory
,
clean
=
True
)
pass
def
getRelativePathUsage
(
self
):
return
True
erp5/util/testnode/SlapOSControler.py
View file @
b74627b0
...
...
@@ -154,7 +154,6 @@ class SlapOSControler(object):
os
.
mkdir
(
self
.
software_root
)
os
.
chmod
(
self
.
software_root
,
0750
)
def
initializeSlapOSControler
(
self
,
slapproxy_log
=
None
,
process_manager
=
None
,
reset_software
=
False
,
software_path_list
=
None
):
self
.
process_manager
=
process_manager
...
...
erp5/util/testnode/UnitTestRunner.py
View file @
b74627b0
...
...
@@ -151,22 +151,5 @@ class UnitTestRunner():
cwd
=
node_test_suite
.
test_suite_directory
,
log_prefix
=
'runTestSuite'
,
get_output
=
False
)
def
getRelativePathUsage
(
self
):
return
False
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