Skip to content

Commit 409c587

Browse files
committed
Externalize installation of codeception/codeception and weirdan/codeception-psalm-module
These packages are runtimes that invoke `psalm/plugin-phpunit` via `exec()`, without sharing codespace with it, and therefore are safe to externalize elsewhere. We can't afford keeping these dependencies co-located with the main `composer.json` / `composer.lock`, as they conflict with non-dev dependencies that we want to explicitly test against.
1 parent aac9717 commit 409c587

File tree

4 files changed

+3882
-3
lines changed

4 files changed

+3882
-3
lines changed

.github/workflows/ci.yml

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,20 +135,38 @@ jobs:
135135
env:
136136
COMPOSER_ROOT_VERSION: dev-master
137137

138+
- name: Install composer tool dependencies (high deps)
139+
run: cd tools/codeception && composer update --prefer-dist --no-interaction
140+
if: ${{matrix.deps == 'high'}}
141+
env:
142+
COMPOSER_ROOT_VERSION: dev-master
143+
138144
- name: Install composer dependencies (low deps)
139145
run: composer update --prefer-dist --no-interaction --prefer-stable --prefer-lowest
140146
if: ${{matrix.deps == 'low'}}
141147
env:
142148
COMPOSER_ROOT_VERSION: dev-master
143149

150+
- name: Install composer tool dependencies (low deps)
151+
run: cd tools/codeception && composer update --prefer-dist --no-interaction --prefer-stable --prefer-lowest
152+
if: ${{matrix.deps == 'low'}}
153+
env:
154+
COMPOSER_ROOT_VERSION: dev-master
155+
144156
- name: Install composer dependencies (stable deps)
145157
run: composer update --prefer-dist --no-interaction --prefer-stable
146158
if: ${{matrix.deps == 'stable'}}
147159
env:
148160
COMPOSER_ROOT_VERSION: dev-master
149161

162+
- name: Install composer tool dependencies (stable deps)
163+
run: cd tools/codeception && composer update --prefer-dist --no-interaction --prefer-stable
164+
if: ${{matrix.deps == 'stable'}}
165+
env:
166+
COMPOSER_ROOT_VERSION: dev-master
167+
150168
- name: Show Psalm version
151169
run: vendor/bin/psalm --version
152170

153171
- name: Run tests
154-
run: vendor/bin/codecept run -v
172+
run: tools/codeception/vendor/bin/codecept run -v

composer.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,8 @@
2222
},
2323
"require-dev": {
2424
"php": "^7.3 || ^8.0",
25-
"codeception/codeception": "^4.0.3",
2625
"phpunit/phpunit": "^10.0 || ^11.0 || ^12.0",
2726
"squizlabs/php_codesniffer": "^3.3.1",
28-
"weirdan/codeception-psalm-module": "^0.11.0",
2927
"weirdan/prophecy-shim": "^1.0 || ^2.0"
3028
},
3129
"extra": {

tools/codeception/composer.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"description": "Psalm plugin for PHPUnit - tools/codeception locked dependencies - used to run tests only!",
3+
"require": {
4+
"php": "~8.1.0 || ~8.2.0 || ~8.3.0 || ~8.4.0",
5+
"codeception/codeception": "^4.0.3",
6+
"weirdan/codeception-psalm-module": "^0.11.0"
7+
},
8+
"scripts": {
9+
"test": "codecept run -v"
10+
},
11+
"config": {
12+
"platform": {
13+
"php": "8.1.99"
14+
}
15+
}
16+
}

0 commit comments

Comments
 (0)