This repository has been archived by the owner on Dec 7, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
95 lines (86 loc) · 2.42 KB
/
mediawiki.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ "*" ]
env:
EXTNAME: PagePort
jobs:
style-php:
name: 'Code Style (PHP)'
runs-on: ubuntu-latest
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.1'
extensions: mbstring, intl
coverage: none
tools: composer, phpcs, phplint
- uses: actions/checkout@v4
- name: Setup Composer
run: composer update
shell: bash
- name: Lint
run: phplint -w --exclude=vendor
shell: bash
- name: PHP Code Sniffer
run: vendor/bin/phpcs -sp --standard=.phpcs.xml .
shell: bash
test:
name: "PHPUnit: MW ${{ matrix.mw }}, PHP ${{ matrix.php }}"
strategy:
fail-fast: false
matrix:
include:
- mw: 'REL1_39'
php: 7.4
runs-on: ubuntu-latest
steps:
# check out the repository!
- name: Checkout
uses: actions/checkout@v3
# - name: Setup upterm session
# uses: lhotari/action-upterm@v1
- name: Test extension
uses: wikiteq/mediawiki-phpunit-action@master
with:
type: extension
php: ${{ matrix.php }}
mwbranch: ${{ matrix.mw }}
extension: PagePort
testgroup: extension-PagePort
security:
name: Static Analysis
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: [ '7.4', '8.1' ]
# Deliberately *not* testing against `master`
mediawiki: [ REL1_39 ]
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, intl, ast
coverage: none
tools: composer
- name: Setup MediaWiki
uses: actions/checkout@v3
with:
repository: wikimedia/mediawiki
ref: ${{ matrix.mediawiki }}
- name: Setup Extension
uses: actions/checkout@v3
with:
path: extensions/${{ env.EXTNAME }}
- name: Setup Composer
run: |
echo '{"extra":{"merge-plugin":{"include":["extensions/*/composer.json","skins/*/composer.json"]}}}' > composer.local.json
composer update
composer update
- name: Phan
run: ./vendor/bin/phan -d extensions/${{ env.EXTNAME }} --minimum-target-php-version=7.4 --long-progress-bar