-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: rename Docker workflow to main.yml and add testing job
- Loading branch information
Showing
5 changed files
with
103 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: 🧪 Tests | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
urbantree: | ||
name: 🧪 UrbanTree | ||
runs-on: ubuntu-latest | ||
steps: | ||
# https://github.com/actions/checkout/tree/11bd71901bbe5b1630ceea73d27597364c9af683 | ||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | ||
# https://github.com/actions/cache/tree/6849a6489940f00c2f30c0fb92c6274307ccb58a | ||
- name: 📦 Cache Composer dependencies | ||
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a | ||
with: | ||
path: /tmp/composer-cache | ||
key: ${{ runner.os }}-${{ hashFiles('**/composer.lock') }} | ||
|
||
# https://github.com/shivammathur/setup-php/tree/c541c155eee45413f5b09a52248675b1a2575231 | ||
- name: 🐘 Setup PHP with extensions | ||
uses: shivammathur/setup-php@c541c155eee45413f5b09a52248675b1a2575231 | ||
with: | ||
php-version: 8.4 | ||
coverage: xdebug | ||
extensions: none, ctype, curl, dom, json, libxml, mbstring, pdo, phar, tokenizer, xml, xmlwriter | ||
ini-values: zend.assertions=1, error_reporting=-1, log_errors_max_len=0, display_errors=On | ||
tools: none | ||
|
||
# https://github.com/php-actions/composer/tree/8a65f0d3c6a1d17ca4800491a40b5756a4c164f3 | ||
- name: 📦 Install Composer dependencies | ||
uses: php-actions/composer@8a65f0d3c6a1d17ca4800491a40b5756a4c164f3 | ||
|
||
- name: 🧪 Run PHPUnit tests with coverage | ||
shell: bash | ||
run: ./vendor/bin/phpunit --log-junit junit.xml --coverage-clover=coverage.xml | ||
|
||
# https://github.com/codecov/test-results-action/tree/9739113ad922ea0a9abb4b2c0f8bf6a4aa8ef820 | ||
- name: 📊 Upload test results to Codecov | ||
if: ${{ !cancelled() }} | ||
uses: codecov/test-results-action@9739113ad922ea0a9abb4b2c0f8bf6a4aa8ef820 | ||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | ||
|
||
# https://github.com/codecov/codecov-action/tree/015f24e6818733317a2da2edd6290ab26238649a | ||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@015f24e6818733317a2da2edd6290ab26238649a | ||
with: | ||
verbose: true | ||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters