From c53298b429c52ec30565fd8cfbb33302ce319f11 Mon Sep 17 00:00:00 2001 From: Xaver Loppenstedt Date: Thu, 16 Nov 2017 20:27:25 +0100 Subject: [PATCH] improve development and CI process --- .travis.yml | 13 ++----------- phpcs.xml.dist | 9 +++++++++ phpunit.xml.dist | 8 ++++++++ 3 files changed, 19 insertions(+), 11 deletions(-) create mode 100644 phpcs.xml.dist create mode 100644 phpunit.xml.dist diff --git a/.travis.yml b/.travis.yml index 3d43344..05c8a65 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,20 +7,11 @@ php: - 7.0 - 7.1 - 7.2 -env: - global: - - PHPCS_DIR=vendor/squizlabs/php_codesniffer - - MO4CS_DIR=vendor/squizlabs/php_codesniffer/src/Standards/MO4 before_script: - phpenv config-rm xdebug.ini - composer install - - mkdir -p $MO4CS_DIR - - cp ruleset.xml $MO4CS_DIR/ - - cp -R Sniffs $MO4CS_DIR/ - - cp -R Tests $MO4CS_DIR/ - - (cd $PHPCS_DIR/src/Standards ; git clone https://github.com/djoos/Symfony-coding-standard.git Symfony ; mv Symfony/Symfony/* Symfony/) script: - - (cd $PHPCS_DIR ; ../../bin/phpunit --filter MO4) - - $PHPCS_DIR/bin/phpcs $MO4CS_DIR --standard=$PHPCS_DIR/phpcs.xml.dist --report=full -np + - vendor/bin/phpunit --filter MO4 + - vendor/bin/phpcs MO4 --report=full -np diff --git a/phpcs.xml.dist b/phpcs.xml.dist new file mode 100644 index 0000000..5b38904 --- /dev/null +++ b/phpcs.xml.dist @@ -0,0 +1,9 @@ + + + The coding standard for PHP_CodeSniffer itself. + + */Tests/*\.(inc|css|js) + vendor/* + + + diff --git a/phpunit.xml.dist b/phpunit.xml.dist new file mode 100644 index 0000000..c3b2d32 --- /dev/null +++ b/phpunit.xml.dist @@ -0,0 +1,8 @@ + + + + + vendor/squizlabs/php_codesniffer/tests/Standards/AllSniffs.php + + +