91 lines (74 loc) · 2.53 KB
/
e2e-tests.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
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions
name: "E2E Tests"
on:
pull_request:
paths-ignore:
- 'compiler/**'
- 'apigen/**'
- 'changelog-generator/**'
push:
branches:
- "1.8.x"
paths-ignore:
- 'compiler/**'
- 'apigen/**'
- 'changelog-generator/**'
env:
COMPOSER_ROOT_VERSION: "1.8.x-dev"
concurrency:
group: e2e-${{ github.head_ref || github.run_id }} # will be canceled on subsequent pushes in pull requests but not branches
cancel-in-progress: true
jobs:
result-cache-e2e-tests:
name: "Result cache E2E tests"
runs-on: ${{ matrix.operating-system }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
operating-system: [ubuntu-latest, windows-latest]
steps:
- name: "Checkout"
uses: actions/checkout@v3
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
php-version: "8.1"
extensions: mbstring
ini-values: memory_limit=256M
- name: "Install dependencies"
run: "composer install --no-interaction --no-progress"
- name: "Tests"
run: |
git clone https://github.com/nikic/PHP-Parser.git tests/e2e/PHP-Parser && git -C tests/e2e/PHP-Parser checkout v3.1.5 && composer install --working-dir tests/e2e/PHP-Parser && vendor/bin/phpunit tests/e2e/ResultCacheEndToEndTest.php
e2e-tests:
name: "E2E tests"
runs-on: "ubuntu-latest"
timeout-minutes: 60
strategy:
matrix:
include:
- script: "bin/phpstan analyse -l 8 -a tests/e2e/data/timecop.php tests/e2e/data/timecop.php"
tools: "pecl"
extensions: "timecop-beta"
- script: "bin/phpstan analyse -l 8 -a tests/e2e/data/soap.php tests/e2e/data/soap.php"
extensions: "soap"
- script: "bin/phpstan analyse -l 8 -a tests/e2e/data/soap.php tests/e2e/data/soap.php"
extensions: ""
- script: "bin/phpstan analyse -l 8 tests/e2e/anon-class/Granularity.php"
extensions: ""
steps:
- name: "Checkout"
uses: actions/checkout@v3
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
php-version: "8.1"
tools: ${{ matrix.tools }}
extensions: ${{ matrix.extensions }}
- name: "Install dependencies"
run: "composer install --no-interaction --no-progress"
- name: "Test"
run: ${{ matrix.script }}