diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml new file mode 100644 index 0000000..353dbc8 --- /dev/null +++ b/.github/workflows/php.yml @@ -0,0 +1,40 @@ +name: PHP Composer + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +permissions: + contents: read + +jobs: + test: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - uses: shivammathur/setup-php@v2 + with: + php-version: '8.2' + + - name: Validate composer.json and composer.lock + run: composer validate --strict + + - name: Cache Composer packages + id: composer-cache + uses: actions/cache@v4 + with: + path: vendor + key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-php- + + - name: Install dependencies + run: composer install --prefer-dist --no-progress + + - name: Run test suite + run: composer test diff --git a/composer.lock b/composer.lock index c0bb1e7..1ed8e67 100644 --- a/composer.lock +++ b/composer.lock @@ -553,23 +553,24 @@ }, { "name": "web-eid/ocsp-php", - "version": "1.1.1", + "version": "1.1.2", "source": { "type": "git", "url": "https://github.com/web-eid/ocsp-php.git", - "reference": "2b039e9f18c2cdfd1fe554e9c8e496e6326ac67e" + "reference": "6a2aa24e5c22bb1477421b118e563d679ddd69b7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/web-eid/ocsp-php/zipball/2b039e9f18c2cdfd1fe554e9c8e496e6326ac67e", - "reference": "2b039e9f18c2cdfd1fe554e9c8e496e6326ac67e", + "url": "https://api.github.com/repos/web-eid/ocsp-php/zipball/6a2aa24e5c22bb1477421b118e563d679ddd69b7", + "reference": "6a2aa24e5c22bb1477421b118e563d679ddd69b7", "shasum": "" }, "require": { + "php": ">=8.1", "phpseclib/phpseclib": "3.0.*" }, "require-dev": { - "phpunit/phpunit": "^11.0.4" + "phpunit/phpunit": "^10.5" }, "type": "library", "autoload": { @@ -610,10 +611,10 @@ ], "description": "OCSP library for PHP", "support": { - "source": "https://github.com/web-eid/ocsp-php/tree/1.1.1", + "source": "https://github.com/web-eid/ocsp-php/tree/1.1.2", "issues": "https://github.com/web-eid/ocsp-php/issues" }, - "time": "2024-03-12T16:06:17+00:00" + "time": "2024-03-15T11:51:14+00:00" } ], "packages-dev": [