mirror of
https://github.com/silverstripe/silverstripe-postgresql
synced 2024-10-22 17:05:45 +02:00
Merge pull request #119 from creative-commoners/pulls/2.3/travis-shared
MNT Travis shared config, use sminnee/phpunit
This commit is contained in:
commit
dd4df9800b
62
.travis.yml
62
.travis.yml
@ -1,53 +1,37 @@
|
||||
language: php
|
||||
version: ~> 1.0
|
||||
|
||||
dist: xenial
|
||||
|
||||
services:
|
||||
- postgresql
|
||||
-
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- $HOME/.composer/cache/files
|
||||
|
||||
php:
|
||||
- 7.1
|
||||
import:
|
||||
- silverstripe/silverstripe-travis-shared:config/provision/standard.yml
|
||||
|
||||
env:
|
||||
global:
|
||||
- DB="PGSQL"
|
||||
- DB=PGSQL
|
||||
- PHPUNIT_TEST=1
|
||||
|
||||
matrix:
|
||||
# Using a custom jobs matrix as every DB=PGSQL and there is alternating PHPUNIT_SUITE's
|
||||
jobs:
|
||||
fast_finish: true
|
||||
include:
|
||||
- php: 7.1
|
||||
env:
|
||||
- PHPUNIT_TEST=framework
|
||||
- REQUIRE_INSTALLER="4.5.x-dev"
|
||||
- PHPUNIT_SUITE="framework"
|
||||
- php: 7.2
|
||||
env:
|
||||
- PHPUNIT_TEST=framework
|
||||
- REQUIRE_INSTALLER="4.6.x-dev"
|
||||
- PHPUNIT_SUITE="postgresql"
|
||||
- php: 7.3
|
||||
env:
|
||||
- PHPUNIT_TEST=framework
|
||||
- php: 7.1
|
||||
env:
|
||||
- PHPUNIT_TEST=postgresql
|
||||
- REQUIRE_INSTALLER="4.7.x-dev"
|
||||
- PHPCS_TEST=1
|
||||
|
||||
before_script:
|
||||
# Init PHP
|
||||
- phpenv rehash
|
||||
- phpenv config-rm xdebug.ini
|
||||
- export PATH=~/.composer/vendor/bin:$PATH
|
||||
- echo 'memory_limit = 2048M' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
|
||||
|
||||
# Install composer dependencies
|
||||
- composer validate
|
||||
- composer require --no-update silverstripe/recipe-cms:4.3.x-dev
|
||||
- composer install --prefer-source --no-interaction --no-progress --no-suggest --optimize-autoloader --verbose --profile
|
||||
- if [[ $PHPCS_TEST ]]; then composer global require squizlabs/php_codesniffer:^3 --prefer-dist --no-interaction --no-progress --no-suggest -o; fi
|
||||
|
||||
script:
|
||||
- if [[ $PHPUNIT_TEST == postgresql ]]; then vendor/bin/phpunit ./tests; fi
|
||||
- if [[ $PHPUNIT_TEST == framework ]]; then vendor/bin/phpunit ./vendor/silverstripe/framework/tests/php; fi
|
||||
- if [[ $PHPCS_TEST ]]; then composer run-script lint; fi
|
||||
- PHPUNIT_SUITE="framework"
|
||||
- php: 7.4
|
||||
env:
|
||||
- REQUIRE_INSTALLER="4.x-dev"
|
||||
- PHPUNIT_COVERAGE_TEST=1
|
||||
- PHPUNIT_SUITE="postgresql"
|
||||
- php: nightly
|
||||
env:
|
||||
- REQUIRE_INSTALLER="4.x-dev"
|
||||
- PHPUNIT_SUITE="framework"
|
||||
- COMPOSER_INSTALL_ARG=--ignore-platform-reqs
|
||||
|
@ -19,7 +19,8 @@
|
||||
"silverstripe/vendor-plugin": "^1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^5.7"
|
||||
"sminnee/phpunit": "^5.7",
|
||||
"squizlabs/php_codesniffer": "^3"
|
||||
},
|
||||
"extra": { },
|
||||
"autoload": {
|
||||
|
@ -2,6 +2,9 @@
|
||||
<ruleset name="SilverStripe">
|
||||
<description>CodeSniffer ruleset for SilverStripe coding conventions.</description>
|
||||
|
||||
<file>code</file>
|
||||
<file>tests</file>
|
||||
|
||||
<!-- base rules are PSR-2 -->
|
||||
<rule ref="PSR2" >
|
||||
<!-- Current exclusions -->
|
||||
|
Loading…
Reference in New Issue
Block a user