Skip to content

Commit

Permalink
Merge pull request #123 from ashnazg/ci
Browse files Browse the repository at this point in the history
CI updates
  • Loading branch information
jaapio authored Jan 12, 2018
2 parents 6934492 + 8e96cc2 commit 208cd45
Show file tree
Hide file tree
Showing 9 changed files with 1,042 additions and 142 deletions.
24 changes: 20 additions & 4 deletions .scrutinizer.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,36 @@
before_commands:
- "composer install --no-dev --prefer-source"

checks:
php:
excluded_dependencies:
- phpstan/phpstan

tools:
external_code_coverage: true
external_code_coverage:
enabled: true
timeout: 300
filter:
excluded_paths: ["docs", "tests", "vendor"]
php_code_sniffer:
enabled: true
config:
standard: PSR2
filter:
paths: ["src/*", "tests/*"]
excluded_paths: []
php_cpd:
enabled: true
excluded_dirs: ["vendor"]
excluded_dirs: ["docs", "tests", "vendor"]
php_cs_fixer:
enabled: true
config:
level: all
filter:
paths: ["src/*", "tests/*"]
php_loc:
enabled: true
excluded_dirs: ["vendor"]
excluded_dirs: ["docs", "tests", "vendor"]
php_mess_detector:
enabled: true
config:
Expand All @@ -24,7 +40,7 @@ tools:
paths: ["src/*"]
php_pdepend:
enabled: true
excluded_dirs: ["tests", "vendor"]
excluded_dirs: ["docs", "tests", "vendor"]
php_analyzer:
enabled: true
filter:
Expand Down
56 changes: 37 additions & 19 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,50 @@
language: php

sudo: false

php:
- 7.0
- 7.1
- 7.2
- nightly
sudo: false

cache:
directories:
- $HOME/.composer/cache
env:

script:
- vendor/bin/phpunit
- composer update --no-interaction --prefer-source
- vendor/bin/phpunit -v
matrix:
fast_finish: true
allow_failures:
- php: nightly

before_script:
- composer install --no-interaction
install:
- composer install --no-interaction --prefer-dist --optimize-autoloader

after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml
jobs:
include:
- stage: test
script:
- vendor/bin/phpunit --no-coverage

- stage: coverage
php: 7.1
script:
- vendor/bin/phpunit
after_script:
- wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml
- wget https://github.com/satooshi/php-coveralls/releases/download/v1.0.1/coveralls.phar && php coveralls.phar --verbose

- stage: lint
php: 7.1
before_script:
- composer create-project symplify/easy-coding-standard temp/ecs
script:
- temp/ecs/bin/ecs check src tests
- vendor/bin/phpstan analyse src --level max --configuration phpstan.neon

cache:
directories:
- $HOME/.composer/cache/files

notifications:
irc: "irc.freenode.org#phpdocumentor"
slack:
secure: "fjumM0h+4w3EYM4dpgqvpiCug7m4sSIC5+HATgwga/Nrc6IjlbWvGOv3JPgD3kQUhi18VmZfUYPmCv916SIbMnv8JWcrSaJXnPCgmxidvYkuzQDIw1HDJbVppGnkmwQA/qjIrM3sIEMfnu/arLRJQLI363aStZzGPxwIa4PDKcg="
email:
- mike.vanriel@naenius.com
- ashnazg@php.net
- boen.robot@gmail.com
- me@mikevanriel.com
- ashnazg@php.net
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
# phpDocumentor/Reflection

[![Build Status]](http://travis-ci.org/phpDocumentor/Reflection)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/badges/quality-score.png?b=develop)](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/?branch=develop)
[![Code Coverage](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/badges/coverage.png?b=develop)](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/?branch=develop)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Travis Status](https://img.shields.io/travis/phpDocumentor/Reflection.svg?label=Linux)](https://travis-ci.org/phpDocumentor/Reflection)
[![Appveyor Status](https://img.shields.io/appveyor/ci/phpDocumentor/Reflection.svg?label=Windows)](https://ci.appveyor.com/project/phpDocumentor/Reflection/branch/master)
[![Coveralls Coverage](https://img.shields.io/coveralls/github/phpDocumentor/Reflection.svg)](https://coveralls.io/github/phpDocumentor/Reflection?branch=master)
[![Scrutinizer Code Coverage](https://img.shields.io/scrutinizer/coverage/g/phpDocumentor/Reflection.svg)](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/?branch=master)
[![Scrutinizer Code Quality](https://img.shields.io/scrutinizer/g/phpDocumentor/Reflection.svg)](https://scrutinizer-ci.com/g/phpDocumentor/Reflection/?branch=master)
[![Stable Version](https://img.shields.io/packagist/v/phpDocumentor/Reflection.svg)](https://packagist.org/packages/phpDocumentor/Reflection)
[![Unstable Version](https://img.shields.io/packagist/vpre/phpDocumentor/Reflection.svg)](https://packagist.org/packages/phpDocumentor/Reflection)


Reflection
==========

Using this library it is possible to statically reflect one or more files and create an object graph representing
your application's structure, including accompanying in-source documentation using DocBlocks.
Expand Down
55 changes: 55 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
build: false
clone_folder: c:\reflection
max_jobs: 3
platform: x86
pull_requests:
do_not_increment_build_number: true
version: '{build}.{branch}'
skip_tags: true
branches:
only:
- develop
- master

environment:
matrix:
- PHP_VERSION: '7.1.13'
VC_VERSION: 'VC14'
- PHP_VERSION: '7.2.1'
VC_VERSION: 'VC15'
matrix:
fast_finish: false

cache:
- c:\php -> appveyor.yml
- '%LOCALAPPDATA%\Composer\files'

init:
- SET PATH=c:\php\%PHP_VERSION%;%PATH%

install:
- IF NOT EXIST c:\php mkdir c:\php
- IF NOT EXIST c:\php\%PHP_VERSION% mkdir c:\php\%PHP_VERSION%
- cd c:\php\%PHP_VERSION%
- IF NOT EXIST php-installed.txt appveyor DownloadFile http://windows.php.net/downloads/releases/php-%PHP_VERSION%-Win32-%VC_VERSION%-x86.zip
- IF NOT EXIST php-installed.txt 7z x php-%PHP_VERSION%-Win32-%VC_VERSION%-x86.zip -y >nul
- IF NOT EXIST php-installed.txt del /Q *.zip
- IF NOT EXIST php-installed.txt copy /Y php.ini-development php.ini
- IF NOT EXIST php-installed.txt echo max_execution_time=1200 >> php.ini
- IF NOT EXIST php-installed.txt echo date.timezone="UTC" >> php.ini
- IF NOT EXIST php-installed.txt echo extension_dir=ext >> php.ini
- IF NOT EXIST php-installed.txt echo extension=php_curl.dll >> php.ini
- IF NOT EXIST php-installed.txt echo extension=php_openssl.dll >> php.ini
- IF NOT EXIST php-installed.txt echo extension=php_mbstring.dll >> php.ini
- IF NOT EXIST php-installed.txt echo extension=php_fileinfo.dll >> php.ini
- IF NOT EXIST php-installed.txt echo zend.assertions=1 >> php.ini
- IF NOT EXIST php-installed.txt echo assert.exception=On >> php.ini
- IF NOT EXIST php-installed.txt appveyor DownloadFile https://getcomposer.org/composer.phar
- IF NOT EXIST php-installed.txt echo @php %%~dp0composer.phar %%* > composer.bat
- IF NOT EXIST php-installed.txt type nul >> php-installed.txt
- cd c:\reflection
- composer install --no-interaction --prefer-dist --no-progress

test_script:
- cd c:\reflection
- vendor/bin/phpunit --no-coverage
5 changes: 3 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
}
},
"require": {
"php": "^7.0",
"php": ">=7.1",
"psr/log": "~1.0",
"nikic/php-parser": "^3.0",
"phpdocumentor/reflection-docblock": "^4.1",
Expand All @@ -29,7 +29,8 @@
"mockery/mockery": "~1.0",
"mikey179/vfsStream": "~1.2",
"squizlabs/php_codesniffer": "^2.5",
"phpunit/phpunit": "^6.4"
"phpunit/phpunit": "~6.5",
"phpstan/phpstan": "^0.9.0"
},
"extra": {
"branch-alias": {
Expand Down
Loading

0 comments on commit 208cd45

Please sign in to comment.