Skip to content

Commit 8d60e48

Browse files
authored
Merge pull request #199 from clue-labs/assert
Update test environment to report failed assertions
2 parents a23e4f0 + 6ac5983 commit 8d60e48

File tree

3 files changed

+17
-2
lines changed

3 files changed

+17
-2
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ jobs:
2727
with:
2828
php-version: ${{ matrix.php }}
2929
coverage: xdebug
30+
ini-file: development
3031
- run: composer install
3132
- run: vendor/bin/phpunit --coverage-text --stderr
3233
if: ${{ matrix.php >= 7.3 }}

phpunit.xml.dist

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22

33
<!-- PHPUnit configuration file with new format for PHPUnit 9.5+ -->
4-
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
55
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.5/phpunit.xsd"
66
bootstrap="vendor/autoload.php"
7+
cacheResult="false"
78
colors="true"
8-
cacheResult="false">
9+
convertDeprecationsToExceptions="true">
910
<testsuites>
1011
<testsuite name="Framework X test suite">
1112
<directory>./tests/</directory>
@@ -19,5 +20,10 @@
1920
</coverage>
2021
<php>
2122
<ini name="error_reporting" value="-1" />
23+
<!-- Evaluate assertions, requires running with "php -d zend.assertions=1 vendor/bin/phpunit" -->
24+
<!-- <ini name="zend.assertions=1" value="1" /> -->
25+
<ini name="assert.active" value="1" />
26+
<ini name="assert.exception" value="1" />
27+
<ini name="assert.bail" value="0" />
2228
</php>
2329
</phpunit>

phpunit.xml.legacy

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,12 @@
1616
<directory>./src/</directory>
1717
</whitelist>
1818
</filter>
19+
<php>
20+
<ini name="error_reporting" value="-1" />
21+
<!-- Evaluate assertions, requires running with "php -d zend.assertions=1 vendor/bin/phpunit" -->
22+
<!-- <ini name="zend.assertions=1" value="1" /> -->
23+
<ini name="assert.active" value="1" />
24+
<ini name="assert.exception" value="1" />
25+
<ini name="assert.bail" value="0" />
26+
</php>
1927
</phpunit>

0 commit comments

Comments
 (0)