Skip to content
Snippets Groups Projects
Commit 9bef6922 authored by Grzegorz Rola's avatar Grzegorz Rola
Browse files

feature(tests): codeception manual

parent 5bcd7fc9
No related branches found
No related tags found
No related merge requests found
......@@ -92,6 +92,33 @@
- 'if [[ ${REPORTPORTAL_AUTHORIZATION} && ${REPORTPORTAL_PROJECT} ]]; then curl -X POST "http://195.201.225.204:8080/api/v1/${REPORTPORTAL_PROJECT}/launch/import" -H "accept: */*" -H "Content-Type: multipart/form-data" -H "${REPORTPORTAL_AUTHORIZATION}" -F "file=@tests/codeception/tests/_output/report.xml;type=text/xml;filename=${CI_PROJECT_NAME}-${CI_COMMIT_REF_SLUG}-codeception.xml"; fi'
- '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}'
.template: &job-codeception-coverage
<<: *job-codeception-test-parallel-manual
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-with-coverage
- 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}
- vendor/bin/codecept run acceptance --steps --xml --html -f --coverage --coverage-xml --coverage-html --verbose
codeception test 1:
<<: *job-codeception-test-parallel-auto
before_script:
......@@ -155,3 +182,7 @@ codeception test manual recorded 4:
before_script:
- export PARALLEL_JOB=4
- cp vendor/wpdesk/wp-codeception/configuration/codeception-with-recorder.dist.yml codeception-with-recorder.dist.yml
codeception code coverage manual:
<<: *job-codeception-coverage
when: maual
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment