Skip to content

Commit 5dd8a80

Browse files
chore: Setup CI
1 parent 31da70b commit 5dd8a80

File tree

4 files changed

+62
-1
lines changed

4 files changed

+62
-1
lines changed

.github/workflows/tests.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: tests
2+
3+
on:
4+
push:
5+
pull_request:
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
strategy:
11+
fail-fast: false
12+
matrix:
13+
php:
14+
- "8.1"
15+
- "8.2"
16+
- "8.3"
17+
- "8.4"
18+
laravel:
19+
- "^10.0"
20+
- "^11.0"
21+
- "^12.0"
22+
exclude:
23+
- laravel: "^11.0"
24+
php: "8.1"
25+
- laravel: "^12.0"
26+
php: "8.1"
27+
28+
name: PHP:${{ matrix.php }} / Laravel:${{ matrix.laravel }} / ${{ matrix.stability }}
29+
30+
steps:
31+
- name: Checkout
32+
uses: actions/checkout@v4
33+
34+
- name: Setup PHP, with composer
35+
uses: shivammathur/setup-php@v2
36+
with:
37+
php-version: ${{ matrix.php }}
38+
tools: composer:v2
39+
coverage: none
40+
41+
- name: Install Composer dependencies
42+
run: composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update --ansi
43+
44+
- name: Install Composer dependencies
45+
run: composer update --no-interaction --no-progress --ansi
46+
47+
- name: Run Unit tests
48+
run: vendor/bin/phpunit --colors=always

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
.phpunit.result.cache
12
vendor

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
},
2222
"require": {
2323
"phpnexus/cwh": "^1.1.14 || ^2.0 || ^3.0.0",
24-
"illuminate/support": "^5.1 || ^6.0 || ^7.0 || ^8.0 || ^9.0|^10.0 || ^11.0"
24+
"illuminate/support": "^5.1 || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0 || ^11.0 || ^12.0"
2525
},
2626
"require-dev": {
2727
"friendsofphp/php-cs-fixer": "^2.12 || ^2.16|^3.14",

phpunit.xml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
4+
bootstrap="vendor/autoload.php"
5+
colors="true"
6+
>
7+
<testsuites>
8+
<testsuite name="Tests">
9+
<directory>tests</directory>
10+
</testsuite>
11+
</testsuites>
12+
</phpunit>

0 commit comments

Comments
 (0)