Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Xiaowu Zhang
slapos
Commits
30d6d98a
Commit
30d6d98a
authored
Aug 10, 2018
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
stask/erp5: generate different runTestSuite according to parameter
parent
2c79bee1
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
315 additions
and
4 deletions
+315
-4
stack/erp5/buildout.cfg
stack/erp5/buildout.cfg
+12
-0
stack/erp5/buildout.hash.cfg
stack/erp5/buildout.hash.cfg
+3
-3
stack/erp5/instance-erp5.cfg.in
stack/erp5/instance-erp5.cfg.in
+1
-0
stack/erp5/instance-zope.cfg.in
stack/erp5/instance-zope.cfg.in
+22
-1
stack/erp5/instance.cfg.in
stack/erp5/instance.cfg.in
+1
-0
stack/erp5/template/run-zelenium-test.py.in
stack/erp5/template/run-zelenium-test.py.in
+276
-0
No files found.
stack/erp5/buildout.cfg
View file @
30d6d98a
...
@@ -158,6 +158,13 @@ rendered = ${buildout:directory}/instance-caucase.cfg
...
@@ -158,6 +158,13 @@ rendered = ${buildout:directory}/instance-caucase.cfg
<= download-base-neo
<= download-base-neo
url = ${:_profile_base_location_}/${:filename}
url = ${:_profile_base_location_}/${:filename}
[template-run-zelenium]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/template/run-zelenium-test.py.in
md5sum = 8c42f98228f0ae9dc16ee2dab739b818
output = ${buildout:directory}/run-zelenium-test.py.in
mode = 755
[check-recipe]
[check-recipe]
recipe = plone.recipe.command
recipe = plone.recipe.command
stop-on-error = true
stop-on-error = true
...
@@ -285,6 +292,7 @@ context =
...
@@ -285,6 +292,7 @@ context =
key root_common root-common:target
key root_common root-common:target
key site_zcml site-zcml:target
key site_zcml site-zcml:target
key sixtunnel_location 6tunnel:location
key sixtunnel_location 6tunnel:location
key template_run_zelenium template-run-zelenium:output
key stunnel_location stunnel:location
key stunnel_location stunnel:location
key template_apache_conf template-apache-backend-conf:target
key template_apache_conf template-apache-backend-conf:target
key template_balancer template-balancer:target
key template_balancer template-balancer:target
...
@@ -549,6 +557,7 @@ eggs = ${neoppod:eggs}
...
@@ -549,6 +557,7 @@ eggs = ${neoppod:eggs}
# Needed for parsing .po files from our Localizer subset
# Needed for parsing .po files from our Localizer subset
polib
polib
selenium
# Needed for Google OAuth
# Needed for Google OAuth
google-api-python-client
google-api-python-client
...
@@ -797,3 +806,6 @@ unidiff = 0.5.5
...
@@ -797,3 +806,6 @@ unidiff = 0.5.5
# deepdiff = 3.3.0
# deepdiff = 3.3.0
jsonpickle = 0.9.6
jsonpickle = 0.9.6
decorator = 4.3.0
decorator = 4.3.0
selenium = 3.8.0
stack/erp5/buildout.hash.cfg
View file @
30d6d98a
...
@@ -66,7 +66,7 @@ md5sum = 0969fbb25b05c02ef3c2d437b2f4e1a0
...
@@ -66,7 +66,7 @@ md5sum = 0969fbb25b05c02ef3c2d437b2f4e1a0
[template]
[template]
filename = instance.cfg.in
filename = instance.cfg.in
md5sum =
330b72acf0752cce5da70b1fcdfac487
md5sum =
50db2da70232c91642c93dc06c982b3c
[monitor-template-dummy]
[monitor-template-dummy]
filename = dummy.cfg
filename = dummy.cfg
...
@@ -74,7 +74,7 @@ md5sum = d41d8cd98f00b204e9800998ecf8427e
...
@@ -74,7 +74,7 @@ md5sum = d41d8cd98f00b204e9800998ecf8427e
[template-erp5]
[template-erp5]
filename = instance-erp5.cfg.in
filename = instance-erp5.cfg.in
md5sum =
9f8851af5faed9d1e346d7dbe0e6db5d
md5sum =
83e0f627633ec3e394dc27d06c627b3b
[template-zeo]
[template-zeo]
filename = instance-zeo.cfg.in
filename = instance-zeo.cfg.in
...
@@ -82,7 +82,7 @@ md5sum = 3e650915959ff31c9c13c84069bbcd35
...
@@ -82,7 +82,7 @@ md5sum = 3e650915959ff31c9c13c84069bbcd35
[template-zope]
[template-zope]
filename = instance-zope.cfg.in
filename = instance-zope.cfg.in
md5sum =
a4dda17c1671ead45ac92b7decc32228
md5sum =
bb251409f0083c6d81e4dc5a770afb31
[template-balancer]
[template-balancer]
filename = instance-balancer.cfg.in
filename = instance-balancer.cfg.in
...
...
stack/erp5/instance-erp5.cfg.in
View file @
30d6d98a
...
@@ -152,6 +152,7 @@ config-caucase-url = ${request-caucase:connection-http-url}
...
@@ -152,6 +152,7 @@ config-caucase-url = ${request-caucase:connection-http-url}
config-cloudooo-url = {{ dumps(slapparameter_dict.get('cloudooo-url', default_cloudooo_url)) }}
config-cloudooo-url = {{ dumps(slapparameter_dict.get('cloudooo-url', default_cloudooo_url)) }}
config-deadlock-debugger-password = ${publish-early:deadlock-debugger-password}
config-deadlock-debugger-password = ${publish-early:deadlock-debugger-password}
config-developer-list = {{ dumps(slapparameter_dict.get('developer-list', [inituser_login])) }}
config-developer-list = {{ dumps(slapparameter_dict.get('developer-list', [inituser_login])) }}
config-saucelabs-dict = {{ dumps(slapparameter_dict.get('saucelabs-dict', {})) }}
config-hosts-dict = {{ dumps(slapparameter_dict.get('hosts-dict', {})) }}
config-hosts-dict = {{ dumps(slapparameter_dict.get('hosts-dict', {})) }}
config-hostalias-dict = {{ dumps(slapparameter_dict.get('hostalias-dict', {})) }}
config-hostalias-dict = {{ dumps(slapparameter_dict.get('hostalias-dict', {})) }}
config-id-store-interval = {{ dumps(slapparameter_dict.get('id-store-interval')) }}
config-id-store-interval = {{ dumps(slapparameter_dict.get('id-store-interval')) }}
...
...
stack/erp5/instance-zope.cfg.in
View file @
30d6d98a
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
{% set zodb_dict = slapparameter_dict['zodb-dict'] -%}
{% set zodb_dict = slapparameter_dict['zodb-dict'] -%}
{% set instance_index_list = range(slapparameter_dict['instance-count']) -%}
{% set instance_index_list = range(slapparameter_dict['instance-count']) -%}
{% set node_id_base = slapparameter_dict['name'] -%}
{% set node_id_base = slapparameter_dict['name'] -%}
{% set saucelabs_dict = slapparameter_dict.get('saucelabs-dict', None) -%}
{% set node_id_index_format = '-%%0%ii' % (len(str(instance_index_list[-1])), ) -%}
{% set node_id_index_format = '-%%0%ii' % (len(str(instance_index_list[-1])), ) -%}
{% set part_list = [] -%}
{% set part_list = [] -%}
{% set publish_list = [] -%}
{% set publish_list = [] -%}
...
@@ -68,6 +69,24 @@ ca-newcerts = ${directory:test-ca-newcerts}
...
@@ -68,6 +69,24 @@ ca-newcerts = ${directory:test-ca-newcerts}
ca-crl = ${directory:test-ca-crl}
ca-crl = ${directory:test-ca-crl}
{% if slapparameter_dict['mysql-test-url-list'] -%}
{% if slapparameter_dict['mysql-test-url-list'] -%}
{% if saucelabs_dict -%}
[test-zelenium-runner-parameter]
configuration = {{ dumps(saucelabs_dict) }}
user = {{ dumps(slapparameter_dict['inituser-login']) }}
password = {{ dumps(slapparameter_dict['inituser-password']) }}
[{{ section('test-zelenium-runner') }}]
recipe = slapos.recipe.template:jinja2
template = {{ parameter_dict['run-zelenium-template'] }}
rendered = ${directory:bin}/runTestSuite
extensions = jinja2.ext.do
context =
import json_module json
key configuration test-zelenium-runner-parameter:configuration
key user test-zelenium-runner-parameter:user
key password test-zelenium-runner-parameter:password
{% else -%}
[{{ section('run-unit-test-userhosts-wrapper') }}]
[{{ section('run-unit-test-userhosts-wrapper') }}]
<= userhosts-wrapper-base
<= userhosts-wrapper-base
wrapped-command-line = ${runUnitTest:wrapper-path}
wrapped-command-line = ${runUnitTest:wrapper-path}
...
@@ -77,7 +96,6 @@ wrapper-path = ${buildout:bin-directory}/runUnitTest
...
@@ -77,7 +96,6 @@ wrapper-path = ${buildout:bin-directory}/runUnitTest
<= userhosts-wrapper-base
<= userhosts-wrapper-base
wrapped-command-line = ${runTestSuite:wrapper-path}
wrapped-command-line = ${runTestSuite:wrapper-path}
wrapper-path = ${buildout:bin-directory}/runTestSuite
wrapper-path = ${buildout:bin-directory}/runTestSuite
{% set connection_string_list = [] -%}
{% set connection_string_list = [] -%}
{% for url in slapparameter_dict['mysql-test-url-list'] -%}
{% for url in slapparameter_dict['mysql-test-url-list'] -%}
{% set parsed_url = urlparse.urlparse(url) -%}
{% set parsed_url = urlparse.urlparse(url) -%}
...
@@ -91,6 +109,7 @@ wrapper-path = ${buildout:bin-directory}/runTestSuite
...
@@ -91,6 +109,7 @@ wrapper-path = ${buildout:bin-directory}/runTestSuite
),
),
) -%}
) -%}
{% endfor -%}
{% endfor -%}
[run-test-common]
[run-test-common]
< = run-common
< = run-common
environment-extra =
environment-extra =
...
@@ -125,6 +144,7 @@ command-name = runTestSuite
...
@@ -125,6 +144,7 @@ command-name = runTestSuite
command-line-extra =
command-line-extra =
--db_list '{{ ','.join(connection_string_list) }}'
--db_list '{{ ','.join(connection_string_list) }}'
{%- endif %}
{%- endif %}
{%- endif %}
[directory]
[directory]
recipe = slapos.cookbook:mkdirectory
recipe = slapos.cookbook:mkdirectory
...
@@ -459,6 +479,7 @@ monitor-httpd-port = {{ next_port() }}
...
@@ -459,6 +479,7 @@ monitor-httpd-port = {{ next_port() }}
monitor-title = {{ slapparameter_dict['name'] }}
monitor-title = {{ slapparameter_dict['name'] }}
password = {{ slapparameter_dict['monitor-passwd'] }}
password = {{ slapparameter_dict['monitor-passwd'] }}
[buildout]
[buildout]
extends =
extends =
{{ logrotate_cfg }}
{{ logrotate_cfg }}
...
...
stack/erp5/instance.cfg.in
View file @
30d6d98a
...
@@ -84,6 +84,7 @@ extra-context =
...
@@ -84,6 +84,7 @@ extra-context =
[dynamic-template-zope-parameters]
[dynamic-template-zope-parameters]
bin-directory = {{ bin_directory }}
bin-directory = {{ bin_directory }}
zope-conf-template = {{ template_zope_conf }}
zope-conf-template = {{ template_zope_conf }}
run-zelenium-template = {{ template_run_zelenium }}
buildout-bin-directory = {{ buildout_bin_directory }}
buildout-bin-directory = {{ buildout_bin_directory }}
6tunnel = {{ sixtunnel_location }}
6tunnel = {{ sixtunnel_location }}
coreutils = {{ coreutils_location }}
coreutils = {{ coreutils_location }}
...
...
stack/erp5/template/run-zelenium-test.py.in
0 → 100644
View file @
30d6d98a
This diff is collapsed.
Click to expand it.
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