|
27 | 27 | uses: "shivammathur/setup-php@v2"
|
28 | 28 | with:
|
29 | 29 | coverage: "none"
|
30 |
| - extensions: "none, curl, json, mbstring, tokenizer" |
| 30 | + extensions: "none, curl, dom, json, mbstring, tokenizer, xml, xmlwriter" |
31 | 31 | php-version: "${{ matrix.php-version }}"
|
32 | 32 |
|
33 | 33 | - name: "Set up problem matchers for PHP"
|
@@ -73,14 +73,30 @@ jobs:
|
73 | 73 | uses: "shivammathur/setup-php@v2"
|
74 | 74 | with:
|
75 | 75 | coverage: "none"
|
76 |
| - extensions: "none, curl" |
| 76 | + extensions: "none, curl, dom, json, mbstring, tokenizer, xml, xmlwriter" |
77 | 77 | php-version: "${{ matrix.php-version }}"
|
78 | 78 |
|
79 | 79 | - name: "Set up problem matchers for PHP"
|
80 | 80 | run: "echo \"::add-matcher::${{ runner.tool_cache }}/php.json\""
|
81 | 81 |
|
| 82 | + - name: "Set up problem matchers for phpunit/phpunit" |
| 83 | + run: "echo \"::add-matcher::${{ runner.tool_cache }}/phpunit.json\"" |
| 84 | + |
| 85 | + - name: "Determine composer cache directory" |
| 86 | + run: "echo \"COMPOSER_CACHE_DIR=$(composer config cache-dir)\" >> $GITHUB_ENV" |
| 87 | + |
| 88 | + - name: "Cache dependencies installed with composer" |
| 89 | + uses: "actions/cache@v3" |
| 90 | + with: |
| 91 | + path: "${{ env.COMPOSER_CACHE_DIR }}" |
| 92 | + key: "php-${{ matrix.php-version }}-composer-${{ hashFiles('composer.lock') }}" |
| 93 | + restore-keys: "php-${{ matrix.php-version }}-composer-" |
| 94 | + |
| 95 | + - name: "Install dependencies with composer" |
| 96 | + run: "composer install --ansi --no-interaction --no-progress" |
| 97 | + |
82 | 98 | - name: "Start built-in web server for PHP"
|
83 | 99 | run: "php -S ${{ env.HTTP_HOST }} .router.php &"
|
84 | 100 |
|
85 |
| - - name: "Run tests" |
86 |
| - run: "php tests/run-tests.php -j3 -q --show-diff" |
| 101 | + - name: "Run phpunit/phpunit" |
| 102 | + run: "vendor/bin/phpunit --colors=always --configuration=tests/phpunit.xml" |
0 commit comments