Skip to content

Commit 3408b14

Browse files
authored
Merge pull request #64 from koriym/php82
Update to PHP 8.2 and PHPUnit 11
2 parents 921be9b + 8e96143 commit 3408b14

15 files changed

Lines changed: 208 additions & 1302 deletions

.github/workflows/ci.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
pull_request:
6+
workflow_dispatch:
7+
8+
jobs:
9+
test:
10+
name: PHP ${{ matrix.php-version }}
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
php-version:
17+
- '8.2'
18+
- '8.3'
19+
- '8.4'
20+
- '8.5'
21+
22+
steps:
23+
- name: Checkout code
24+
uses: actions/checkout@v4
25+
26+
- name: Setup PHP
27+
uses: shivammathur/setup-php@v2
28+
with:
29+
php-version: ${{ matrix.php-version }}
30+
extensions: dom, libxml, simplexml
31+
coverage: none
32+
33+
- name: Validate composer.json
34+
run: composer validate --strict --no-check-lock
35+
36+
- name: Get Composer cache directory
37+
id: composer-cache
38+
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
39+
40+
- name: Cache Composer dependencies
41+
uses: actions/cache@v4
42+
with:
43+
path: ${{ steps.composer-cache.outputs.dir }}
44+
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
45+
restore-keys: ${{ runner.os }}-composer-
46+
47+
- name: Install dependencies
48+
run: composer install --prefer-dist --no-progress --no-suggest
49+
50+
- name: Run tests
51+
run: vendor/bin/phpunit --no-coverage

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
build
22
composer.phar
3+
composer.lock
34
vendor/
45
bin/

.travis.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Nocarrier\Hal
22
=============
33

4-
[![Build Status](https://secure.travis-ci.org/blongden/hal.png)](http://travis-ci.org/blongden/hal)
4+
[![CI](https://github.com/blongden/hal/actions/workflows/ci.yml/badge.svg)](https://github.com/blongden/hal/actions/workflows/ci.yml)
55
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/blongden/hal/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/blongden/hal/?branch=master)
66

77
This is a library for creating documents in the [application/hal+json and application/hal+xml][1] hypermedia formats

composer.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,12 @@
1313
}
1414
],
1515
"require": {
16-
"php": ">=5.3.0",
17-
"psr/link": "~1.0"
16+
"php": "^8.2",
17+
"psr/link": "^1.0"
1818
},
1919
"require-dev": {
20-
"phpunit/phpunit": "^7.0 || ^6.4 || ^5.7 || ^4.8.35"
20+
"phpunit/phpunit": "^11"
2121
},
22-
"minimum-stability": "dev",
2322
"autoload": {
2423
"psr-4": {
2524
"Nocarrier\\": "src"
@@ -29,8 +28,5 @@
2928
"psr-4": {
3029
"Nocarrier\\Tests\\": "tests/Hal"
3130
}
32-
},
33-
"config": {
34-
"bin-dir": "bin"
3531
}
3632
}

0 commit comments

Comments
 (0)