1
0
mirror of synced 2025-02-21 17:33:13 +03:00

update build

This commit is contained in:
Akolzin Dmitry 2020-02-25 13:45:17 +03:00
parent 6fa5e3d511
commit cc4e8c9c5b
18 changed files with 33 additions and 39 deletions

View File

@ -1,34 +1,26 @@
language: php os: linux
dist: trusty dist: trusty
sudo: false language: php
php: if: tag IS blank
- 5.6
- 7.0
- 7.1
env: stages:
- WP_VERSION=latest WP_MULTISITE=0 - test
- deploy
matrix:
fast_finish: true
include:
- php: 7.2
env: WP_VERSION=latest WP_MULTISITE=0 RUN_PHPCS=1
before_script: before_script:
- bash tests/bin/install.sh wc_retailcrm_test root '' localhost $WP_VERSION - bash tests/bin/install.sh wc_retailcrm_test root '' localhost $WP_VERSION
script: script: make tests
- bash tests/bin/script.sh
deploy: jobs:
skip_cleanup: true include:
provider: script - php: 5.6
script: make env: WP_VERSION=latest WP_MULTISITE=0
on: - stage: deploy
php: 7.2 deploy:
branch: master cleanup: false
condition: "$DEPLOY = true" provider: script
script: make
if: branch = master AND type = push AND fork = false

View File

@ -20,3 +20,18 @@ svn_push: /tmp/svn_plugin_dir
remove_dir: remove_dir:
rm -rf /tmp/svn_plugin_dir rm -rf /tmp/svn_plugin_dir
compile_pot:
msgfmt resources/pot/retailcrm-ru_RU.pot -o src/languages/retailcrm-ru_RU.mo
msgfmt resources/pot/retailcrm-es_ES.pot -o src/languages/retailcrm-es_ES.mo
install:
bash tests/bin/install.sh
composer install
tests: install
ifeq ($(USE_COMPOSER),1)
vendor/phpunit/phpunit/phpunit -c phpunit.xml.dist
else
phpunit -c phpunit.xml.dist
endif

View File

@ -13,7 +13,7 @@
> >
<testsuites> <testsuites>
<testsuite name="Retailcrm WooCommerce Test Suite"> <testsuite name="Retailcrm WooCommerce Test Suite">
<directory suffix=".php">tests/phpunit</directory> <directory suffix=".php">tests</directory>
</testsuite> </testsuite>
</testsuites> </testsuites>
<filter> <filter>

View File

@ -1,5 +0,0 @@
#!/usr/bin/env bash
DIRECTORY=$(cd `dirname $0` && pwd)
msgfmt $DIRECTORY/../pot/retailcrm-ru_RU.pot -o $DIRECTORY/../../src/languages/retailcrm-ru_RU.mo
msgfmt $DIRECTORY/../pot/retailcrm-es_ES.pot -o $DIRECTORY/../../src/languages/retailcrm-es_ES.mo

View File

@ -1,8 +0,0 @@
#!/usr/bin/env bash
if [[ ${RUN_PHPCS} == 1 ]]; then
composer install
vendor/phpunit/phpunit/phpunit -c phpunit.xml.dist
else
phpunit -c phpunit.xml.dist
fi