Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
G
gitlab-ci
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wpdesk
gitlab-ci
Commits
481fed6a
Commit
481fed6a
authored
4 years ago
by
Grzegorz Rola
Browse files
Options
Downloads
Patches
Plain Diff
Feature/codeception parallel
parent
e370b902
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
gitlab-ci-1.2.yml
+3
-0
3 additions, 0 deletions
gitlab-ci-1.2.yml
includes/tests/codeception-parallel.yml
+154
-0
154 additions, 0 deletions
includes/tests/codeception-parallel.yml
with
157 additions
and
0 deletions
gitlab-ci-1.2.yml
+
3
−
0
View file @
481fed6a
...
...
@@ -33,6 +33,9 @@ include:
-
project
:
'
wpdesk/gitlab-ci'
ref
:
'
master'
file
:
'
/includes/tests/codeception.yml'
-
project
:
'
wpdesk/gitlab-ci'
ref
:
'
master'
file
:
'
/includes/tests/codeception-parallel.yml'
-
project
:
'
wpdesk/gitlab-ci'
ref
:
'
master'
file
:
'
/includes/tests/codeception-smoke.yml'
...
...
This diff is collapsed.
Click to expand it.
includes/tests/codeception-parallel.yml
0 → 100644
+
154
−
0
View file @
481fed6a
.template
:
&job-codeception-test-parallel
tags
:
-
codeception
image
:
name
:
wpdesknet/codeception:11
entrypoint
:
[
"
"
]
dependencies
:
-
prepare npm assets
-
prepare translations
variables
:
WP_CLI_CACHE_DIR
:
/cache/wp-cli
APACHE_DOCUMENT_ROOT
:
${CI_PROJECT_DIR}/tests/wordpress
CI_DEBUG_SERVICES
:
trace
SCREEN_WIDTH
:
1200
SCREEN_HEIGHT
:
1200
services
:
-
name
:
mysql:5.6
alias
:
mysqltests
-
name
:
wpdesknet/wordpress:50
alias
:
wootests
-
name
:
selenium/standalone-chrome:latest
alias
:
chrome
artifacts
:
when
:
always
expire_in
:
1 month
name
:
"
acceptance
logs"
paths
:
-
tests/codeception/tests/_output
-
${APACHE_DOCUMENT_ROOT}/wp-content/debug.log
-
${APACHE_DOCUMENT_ROOT}/wp-content/uploads/wpdesk-logs/wpdesk_debug.log
reports
:
junit
:
tests/codeception/tests/_output/report.xml
stage
:
tests
allow_failure
:
false
interruptible
:
true
script
:
-
export DEPENDENT_PLUGINS_DIR=${CI_PROJECT_DIR}/tests/dependent_plugins
-
mkdir -p /cache/wp-cli
-
export MYSQL_IP=$(awk '/^[[:space:]]*($|#)/{next} /mysqltests/{print $1; exit}' /etc/hosts)
-
export WOOTESTS_IP=$(awk '/^[[:space:]]*($|#)/{next} /wootests/{print $1; exit}' /etc/hosts)
-
cd ${CI_PROJECT_DIR}
-
mkdir -p /project
-
cd ${CI_PROJECT_DIR}
-
mkdir -p ${APACHE_DOCUMENT_ROOT}
-
cd ${APACHE_DOCUMENT_ROOT}
-
cd ${CI_PROJECT_DIR}
-
composer prepare-wordpress-for-codeception
-
composer prepare-local-codeception-tests
-
mkdir -p ${CI_PROJECT_DIR}/tests/codeception/tests/_output
-
mkdir -p ${CI_PROJECT_DIR}/tests/codeception/tests/acceptance
-
mkdir -p ${CI_PROJECT_DIR}/tests/codeception/tests/functional
-
mkdir -p ${CI_PROJECT_DIR}/tests/codeception/tests/unit
-
chmod -R a+w ${APACHE_DOCUMENT_ROOT}/wp-content/uploads
-
touch ${APACHE_DOCUMENT_ROOT}/wp-content/debug.log
-
chmod a+w ${APACHE_DOCUMENT_ROOT}/wp-content/debug.log
-
echo "End before"
-
cd ${CI_PROJECT_DIR}
-
composer prepare-parallel-codeception-tests
4
-
vendor/bin/codecept run acceptance $PARALLEL_JOB --steps --xml --html -f --verbose
after_script
:
-
rm -r ${APACHE_DOCUMENT_ROOT}
.template
:
&job-codeception-test-parallel-auto
<<
:
*job-codeception-test-parallel
only
:
refs
:
-
master
-
main
-
devel
-
tags
variables
:
-
$CODECEPTION_PARALLEL
.template
:
&job-codeception-test-parallel-manual
<<
:
*job-codeception-test-parallel
when
:
manual
allow_failure
:
true
only
:
variables
:
-
$CODECEPTION_PARALLEL
.template
:
&job-codeception-test-parallel-manual-recorded
<<
:
*job-codeception-test-parallel-manual
when
:
manual
allow_failure
:
true
before_script
:
-
cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
after_script
:
-
rm -r ${APACHE_DOCUMENT_ROOT}
-
'
curl
-X
POST
--data-urlencode
"payload={\"text\":
\"Testy
projektu
<https://gitlab.com/wpdesk/${CI_PROJECT_NAME}|${CI_PROJECT_NAME}>
zostały
wykonane.
<https://wpdesk.gitlab.io/-/${CI_PROJECT_NAME}/-/jobs/${CI_JOB_ID}/artifacts/tests/codeception/tests/_output/records.html|Zapis
testu>\",
}"
https://hooks.slack.com/services/${SLACK_AUTH}'
codeception test 1
:
<<
:
*job-codeception-test-parallel
before_script
:
-
export PARALLEL_JOB=1
codeception test 2
:
<<
:
*job-codeception-test-parallel
before_script
:
-
export PARALLEL_JOB=2
codeception test 3
:
<<
:
*job-codeception-test-parallel
before_script
:
-
export PARALLEL_JOB=3
codeception test 4
:
<<
:
*job-codeception-test-parallel
before_script
:
-
export PARALLEL_JOB=4
codeception test manual 1
:
<<
:
*job-codeception-test-parallel-manual
before_script
:
-
export PARALLEL_JOB=1
codeception test manual 2
:
<<
:
*job-codeception-test-parallel-manual
before_script
:
-
export PARALLEL_JOB=2
codeception test manual 3
:
<<
:
*job-codeception-test-parallel-manual
before_script
:
-
export PARALLEL_JOB=3
codeception test manual 4
:
<<
:
*job-codeception-test-parallel-manual
before_script
:
-
export PARALLEL_JOB=4
codeception test manual recorded 1
:
<<
:
*job-codeception-test-parallel-manual-recorded
before_script
:
-
export PARALLEL_JOB=1
-
cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
codeception test manual recorded 2
:
<<
:
*job-codeception-test-parallel-manual-recorded
before_script
:
-
export PARALLEL_JOB=2
-
cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
codeception test manual recorded 3
:
<<
:
*job-codeception-test-parallel-manual-recorded
before_script
:
-
export PARALLEL_JOB=3
-
cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
codeception test manual recorded 4
:
<<
:
*job-codeception-test-parallel-manual-recorded
before_script
:
-
export PARALLEL_JOB=4
-
cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment