Skip to content
This repository was archived by the owner on Mar 1, 2023. It is now read-only.

Commit 6d5e9fc

Browse files
authored
Develop (#11)
Updated php-cs-fixer to stable v2 Updated tests Remove scrutinizer support and changelog Upgrade to php 7.1
1 parent 60d8eb5 commit 6d5e9fc

File tree

9 files changed

+1657
-467
lines changed

9 files changed

+1657
-467
lines changed

.gitignore

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1-
vendor/
1+
/vendor
2+
/build
3+
4+
composer.phar
25
.php_cs.cache
3-
build/
6+
.DS_Store
7+
Thumbs.db

.php_cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ $config->getFinder()
77
->in(__DIR__)
88
->exclude('build')
99
->exclude('vendor')
10-
->exclude('tests')
1110
->name('*.php')
1211
->ignoreDotFiles(true)
1312
->ignoreVCS(true);

.travis.yml

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,30 @@
11
language: php
22

3-
sudo: false
4-
53
php:
6-
- 7.0
74
- 7.1
85

6+
env:
7+
global:
8+
- SEND_COVERAGE=false
9+
- PHPSTAN=false
10+
911
matrix:
10-
allow_failures:
11-
- php: nightly
1212
fast_finish: true
13+
include:
14+
- php: 7.1
15+
env: SEND_COVERAGE=true
16+
# phpstan
17+
- php: 7.1
18+
env: PHPSTAN=true
19+
20+
sudo: false
1321

1422
cache:
1523
directories:
1624
- $HOME/.composer/cache
1725
- $HOME/.php-cs-fixer
1826

1927
before_install:
20-
- composer self-update
2128
- composer validate
2229

2330
install:
@@ -28,9 +35,9 @@ before_script:
2835

2936
script:
3037
- mkdir -p build/logs
31-
- vendor/bin/phpunit -c phpunit.xml.dist --verbose
32-
- vendor/bin/php-cs-fixer fix --config=.php_cs --verbose --diff --dry-run
38+
- if [[ "$PHPSTAN" = false && "$SEND_COVERAGE" = true ]]; then ./vendor/bin/php-cs-fixer fix --verbose --diff --dry-run; fi
39+
- if [[ "$PHPSTAN" = false && "$SEND_COVERAGE" = true ]]; then ./vendor/bin/phpunit -c phpunit.xml.dist --verbose --coverage-clover=coverage.xml; fi
40+
- if [[ "$PHPSTAN" = true && "$SEND_COVERAGE" = false ]]; then ./vendor/bin/phpstan analyse -c phpstan.neon -l 6 src; fi
3341

34-
after_script:
35-
- wget https://scrutinizer-ci.com/ocular.phar
36-
- php ocular.phar code-coverage:upload --format=php-clover build/logs/coverage.clover
42+
after_success:
43+
- if [[ "$PHPSTAN" = false && "$SEND_COVERAGE" = true ]]; then bash <(curl -s https://codecov.io/bash); fi

composer.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,12 @@
2424
}
2525
],
2626
"require": {
27-
"php" : "^7.0",
28-
"friendsofphp/php-cs-fixer" : "^2.0"
27+
"php" : "^7.1",
28+
"friendsofphp/php-cs-fixer" : "^2.3.2"
2929
},
3030
"require-dev": {
31-
"phpunit/phpunit" : "^5.1"
31+
"phpunit/phpunit" : "^6.1",
32+
"phpstan/phpstan" : "^0.7"
3233
},
3334
"autoload": {
3435
"psr-4": {
@@ -37,7 +38,7 @@
3738
},
3839
"autoload-dev": {
3940
"psr-4": {
40-
"Narrowspark\\CS\\Config\\Test\\" : "test"
41+
"Narrowspark\\CS\\Config\\Test\\" : "tests"
4142
}
4243
},
4344
"config": {

0 commit comments

Comments
 (0)