Skip to content

Commit

Permalink
Merge pull request #17 from DavidGoodwin/master
Browse files Browse the repository at this point in the history
add github actions build with php 7.2 <-> 8.3
  • Loading branch information
zakirullin authored Sep 10, 2024
2 parents 71c6696 + 5c7af60 commit 7ddb3d5
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 6 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: GitHub Build

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

permissions:
contents: read

jobs:
build:
strategy:
matrix:
php-versions: ['7.2', '7.4', '8.0', '8.1', '8.2', '8.3']

runs-on: ubuntu-latest

steps:

- uses: actions/checkout@v4

- name: setup PHP.
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}

- name: php version check
run: php -v

- name: Validate composer.json
run: composer validate --strict

- name: run composer (install dependencies)
run: composer install --prefer-dist --no-progress

- name: run psalm (static analysis)
run: vendor/bin/psalm

- name: run unit tests
run: composer test


16 changes: 11 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,21 @@
}
],
"config": {
"sort-packages": true
"sort-packages": true,
"allow-plugins": {
"infection/extension-installer": true
}
},
"require": {
"php": "^7.2|^8.0"
},
"require-dev": {
"infection/infection": "^0.15|^0.20",
"phpunit/phpunit": "^8.0",
"vimeo/psalm": "4.16.1"
"composer/xdebug-handler": "^1.4|2.0",
"infection/infection": "^0.15|^0.20|^0.27",
"phpunit/phpunit": "^8.0|^9.0",
"symfony/string": "^5.4.43",
"sanmai/pipeline": "5.2.1",
"vimeo/psalm": "4.16.1|5.*"
},
"autoload": {
"psr-4": {
Expand All @@ -42,7 +48,7 @@
},
"scripts": {
"test": [
"phpunit --stderr --coverage-text"
"@php vendor/bin/phpunit --stderr --coverage-text"
],
"coverage": "phpunit --coverage-html=coverage"
},
Expand Down
5 changes: 4 additions & 1 deletion src/MessInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

use ArrayAccess;

/**
* @psalm-suppress MissingTemplateParam
*/
interface MessInterface extends ArrayAccess
{
/**
Expand Down Expand Up @@ -333,4 +336,4 @@ public function findArrayOfStringToMixed(): ?array;
*/
#[\ReturnTypeWillChange]
public function offsetGet($offset);
}
}

0 comments on commit 7ddb3d5

Please sign in to comment.