]> git.mxchange.org Git - friendica.git/commitdiff
Add CI step for PHPStan in addons folder
authorArt4 <art4@wlabs.de>
Tue, 25 Feb 2025 14:33:56 +0000 (14:33 +0000)
committerArt4 <art4@wlabs.de>
Tue, 25 Feb 2025 14:33:56 +0000 (14:33 +0000)
.github/workflows/code-quality.yml
.woodpecker/.phpunit.yml

index 9c8e20ee5f4c7a28f4d15bd5ca8c0ce7416bf777..bcca97c9080140b5dc9a7cc7ac283954eb3dae46 100644 (file)
@@ -76,6 +76,38 @@ jobs:
       - name: Run PHPStan
         run: composer run phpstan
 
+  phpstan-addons:
+    name: PHPStan in addons (PHP ${{ matrix.php }})
+    runs-on: ubuntu-latest
+
+    strategy:
+      fail-fast: false
+      matrix:
+        operating-system: ['ubuntu-latest']
+        php: ['8.4']
+
+    steps:
+      - name: Checkout
+        uses: actions/checkout@v3
+        with:
+          fetch-depth: 2
+
+      - name: Setup PHP with composer and extensions
+        uses: shivammathur/setup-php@v2 #https://github.com/shivammathur/setup-php
+        with:
+          php-version: ${{ matrix.php }}
+          coverage: xdebug
+          tools: none
+
+      - name: Clone addon repository
+        run: git clone -b develop --single-branch https://git.friendi.ca/friendica/friendica-addons.git addon
+
+      - name: Install Composer dependencies
+        uses: "ramsey/composer-install@v2"
+
+      - name: Run PHPStan in addons
+        run: composer run phpstan-addons
+
   phpmd:
     name: PHPMD (PHP ${{ matrix.php }})
     runs-on: ubuntu-latest
index 04c66bcb9760da80cb67ce21f04ddeb2dab3f386..3b8f466d13a577560f059210fed92c0b3d281e05 100644 (file)
@@ -64,9 +64,16 @@ steps:
     image: friendicaci/php${PHP_MAJOR_VERSION}:php${PHP_VERSION}
     when:
       matrix:
-        PHP_MAJOR_VERSION: 8.2
+        PHP_MAJOR_VERSION: 8.3
     commands:
       - bin/composer.phar run phpstan;
+  phpstan-addons:
+    image: friendicaci/php${PHP_MAJOR_VERSION}:php${PHP_VERSION}
+    when:
+      matrix:
+        PHP_MAJOR_VERSION: 8.3
+    commands:
+      - bin/composer.phar run phpstan-addons;
   test:
     image: friendicaci/php${PHP_MAJOR_VERSION}:php${PHP_VERSION}
     environment: