Skip to content

Commit

Permalink
Tidies up phpunit.
Browse files Browse the repository at this point in the history
  • Loading branch information
typhonius committed Oct 8, 2020
1 parent ccc03f9 commit 6cf85f5
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 37 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ jobs:
- name: Install dependencies
if: steps.composer-cache.outputs.cache-hit != 'true'
run: composer install --prefer-dist --no-progress --no-suggest
run: composer install --prefer-source --no-progress --no-suggest --no-interaction

- name: Setup PCOV
run: |
composer require pcov/clobber
vendor/bin/pcov clobber
- name: Run test suite
run: composer run-script ci-test
run: composer run-script test

9 changes: 1 addition & 8 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,21 +40,14 @@
],
"cs": "phpcs --standard=PSR12 -n src tests --ignore=./tests/logs/*",
"cbf": "phpcbf --standard=PSR2 -n src tests",
"unit": "phpunit --colors=always --coverage-clover ./tests/logs/clover.xml",
"ci-unit": "php -dpcov.enabled=1 -dpcov.directory=. -dpcov.exclude='~vendor~' ./vendor/bin/phpunit --configuration=phpunit.ci.xml --testdox",
"unit": "php -dpcov.enabled=1 -dpcov.directory=. -dpcov.exclude='~vendor~' ./vendor/bin/phpunit --configuration=phpunit.xml --testdox",
"stan": "phpstan analyse --level 5 src tests",
"test": [
"@lint",
"@unit",
"@cs",
"@stan"
],
"ci-test": [
"@lint",
"@ci-unit",
"@cs",
"@stan"
],
"release": [
"release VERSION"
],
Expand Down
25 changes: 0 additions & 25 deletions phpunit.ci.xml

This file was deleted.

13 changes: 11 additions & 2 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="vendor/autoload.php">
<phpunit
bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
verbose="true"
>
<testsuites>
<testsuite name="Acquia Cloud PHP SDK Binding">
<directory suffix=".php">./tests/</directory>
Expand All @@ -11,6 +18,8 @@
</whitelist>
</filter>
<logging>
<log type="coverage-clover" target="tests/logs/clover.xml"/>
<log type="coverage-text" target="php://stdout" showUncoveredFiles="true"/>
<log type="coverage-clover" target="tests/logs/clover.xml" showUncoveredFiles="true"/>
<log type="coverage-html" target="tests/logs/phpunit.html" lowUpperBound="35" highLowerBound="70"/>
</logging>
</phpunit>

0 comments on commit 6cf85f5

Please sign in to comment.