mirror of
https://github.com/Icinga/icingadb-web.git
synced 2026-05-28 04:36:06 -04:00
php: Split phpstan tests into a separate workflow (#1004)
This commit is contained in:
commit
68d5227300
2 changed files with 22 additions and 14 deletions
17
.github/workflows/php.yml
vendored
17
.github/workflows/php.yml
vendored
|
|
@ -22,7 +22,7 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout code base
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
|
|
@ -31,14 +31,7 @@ jobs:
|
|||
tools: phpcs
|
||||
|
||||
- name: Setup dependencies
|
||||
run: |
|
||||
composer require -n --no-progress overtrue/phplint phpstan/phpstan
|
||||
sudo git clone --depth 1 https://github.com/Icinga/icingaweb2.git /icingaweb2
|
||||
sudo git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-library.git /usr/share/icinga-php/ipl
|
||||
sudo git clone --depth 1 -b snapshot/nightly https://github.com/Icinga/icinga-php-thirdparty.git /usr/share/icinga-php/vendor
|
||||
sudo git clone --depth 1 https://github.com/Icinga/icingaweb2-module-reporting.git /usr/share/icingaweb2-modules/reporting
|
||||
sudo git clone --depth 1 https://github.com/Icinga/icingaweb2-module-pdfexport.git /usr/share/icingaweb2-modules/pdfexport
|
||||
sudo git clone --depth 1 https://github.com/Icinga/icingaweb2-module-x509.git /usr/share/icingaweb2-modules/x509
|
||||
run: composer require -n --no-progress overtrue/phplint
|
||||
|
||||
- name: PHP Lint
|
||||
if: ${{ ! cancelled() }}
|
||||
|
|
@ -48,10 +41,6 @@ jobs:
|
|||
if: ${{ ! cancelled() }}
|
||||
run: phpcs -wps --colors
|
||||
|
||||
- name: PHPStan
|
||||
if: ${{ ! cancelled() }}
|
||||
run: ./vendor/bin/phpstan analyse
|
||||
|
||||
test:
|
||||
name: Unit tests with php ${{ matrix.php }} on ${{ matrix.os }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
|
@ -67,7 +56,7 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout code base
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
|
|
|
|||
19
.github/workflows/phpstan.yml
vendored
Normal file
19
.github/workflows/phpstan.yml
vendored
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
name: PHPStan
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
phpstan:
|
||||
uses: icinga/github-actions/.github/workflows/phpstan.yml@main
|
||||
with:
|
||||
phpExtensions: ldap
|
||||
dependencies: |
|
||||
{
|
||||
"/icingaweb2" : "https://github.com/Icinga/icingaweb2.git",
|
||||
"/usr/share/icingaweb2-modules/x509" : "https://github.com/Icinga/icingaweb2-module-x509.git",
|
||||
"/usr/share/icingaweb2-modules/pdfexport" : "https://github.com/Icinga/icingaweb2-module-pdfexport.git",
|
||||
"/usr/share/icingaweb2-modules/reporting" : "https://github.com/Icinga/icingaweb2-module-reporting.git"
|
||||
}
|
||||
Loading…
Reference in a new issue