Skip to content

Commit 63dbfe2

Browse files
authored
Support Laravel 12 (#6)
* Laravel 12 * Update run-tests.yml * Update run-tests.yml * Run apt-get update * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Create requirements.txt * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml * Update run-tests.yml
1 parent af5e586 commit 63dbfe2

File tree

3 files changed

+25
-13
lines changed

3 files changed

+25
-13
lines changed

.github/workflows/run-tests.yml

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ on:
77
pull_request:
88
branches:
99
- "*"
10-
schedule:
11-
- cron: '0 0 * * *'
1210

1311
jobs:
1412
php-tests:
@@ -19,23 +17,34 @@ jobs:
1917

2018
strategy:
2119
matrix:
22-
php: [8.3, 8.2, 8.1]
23-
laravel: [11.*, 10.*, 9.*]
24-
dependency-version: [prefer-lowest, prefer-stable]
20+
php: [8.4, 8.3, 8.2, 8.1]
21+
laravel: [12.*, 11.*, 10.*, 9.*]
22+
dependency-version: [prefer-stable]
2523
exclude:
2624
- laravel: 11.*
2725
php: 8.1
26+
- laravel: 12.*
27+
php: 8.1
2828

2929
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }}
3030

3131
steps:
3232
- name: Checkout code
3333
uses: actions/checkout@v2
3434

35+
- uses: actions/setup-python@v5
36+
with:
37+
python-version: '3.13'
38+
cache: 'pip' # caching pip dependencies
39+
40+
- name: Install Dependencies
41+
run: |
42+
python -m pip install --upgrade pip
43+
python -m pip install Pillow numpy filetype setuptools wheel twine
44+
3545
- name: Install weasyprint
3646
run: |
37-
sudo apt install python3-pip python3-cffi python3-brotli libpango-1.0-0 libharfbuzz0b libpangoft2-1.0-0
38-
sudo pip install weasyprint
47+
pip install -r requirements.txt
3948
weasyprint --info
4049
whereis weasyprint
4150
@@ -52,4 +61,6 @@ jobs:
5261
composer update --${{ matrix.dependency-version }} --prefer-dist --no-progress
5362
5463
- name: Execute Unit Tests
55-
run: composer test
64+
run: |
65+
export WEASYPRINT_BINARY=weasyprint
66+
composer test

composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@
1414
}
1515
],
1616
"require": {
17-
"php": ">=8.1",
18-
"illuminate/support": "^9|^10|^11",
19-
"illuminate/filesystem": "^9|^10|^11",
20-
"pontedilana/php-weasyprint": "^1.3"
17+
"php": "^8.1",
18+
"illuminate/support": "^9|^10|^11|^12",
19+
"illuminate/filesystem": "^9|^10|^11|^12",
20+
"pontedilana/php-weasyprint": "^1.5"
2121
},
2222
"require-dev": {
23-
"orchestra/testbench": "^7|^8|^9",
23+
"orchestra/testbench": "^7|^8|^9|^10",
2424
"squizlabs/php_codesniffer": "^3.5"
2525
},
2626
"autoload": {

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
weasyprint >= 64

0 commit comments

Comments
 (0)