Skip to content

Commit 9997ebf

Browse files
authored
Merge pull request #5 from utopia-php/feat-swoole-support
Feat swoole support
2 parents 437f002 + 9367bc3 commit 9997ebf

22 files changed

Lines changed: 2331 additions & 722 deletions

.github/workflows/tests.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: "Tests"
2+
3+
on:
4+
pull_request:
5+
push:
6+
branches:
7+
- main
8+
9+
jobs:
10+
tests:
11+
name: Tests (PHP ${{ matrix.php }})
12+
runs-on: ubuntu-latest
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
php: ['8.2', '8.3', '8.4']
17+
18+
steps:
19+
- name: Checkout repository
20+
uses: actions/checkout@v4
21+
22+
- name: Run tests
23+
run: |
24+
PHP_VERSION=${{ matrix.php }} docker compose run --rm tests sh -c "
25+
git config --global --add safe.directory /app &&
26+
composer update --no-interaction &&
27+
composer test
28+
"

composer.json

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"Utopia\\Telemetry\\": "src/Telemetry"
1414
}
1515
},
16+
"autoload-dev": {
17+
"psr-4": {
18+
"Tests\\Telemetry\\": "tests/Telemetry"
19+
}
20+
},
1621
"scripts": {
1722
"lint": "vendor/bin/pint --test",
1823
"format": "vendor/bin/pint",
@@ -24,16 +29,21 @@
2429
"ext-protobuf": "*",
2530
"ext-opentelemetry": "*",
2631
"php": ">=8.0",
27-
"open-telemetry/sdk": "^1.1",
28-
"symfony/http-client": "^7.1",
29-
"nyholm/psr7": "^1.8",
30-
"open-telemetry/exporter-otlp": "^1.1"
32+
"nyholm/psr7": "1.*",
33+
"open-telemetry/exporter-otlp": "1.*",
34+
"open-telemetry/sdk": "1.*",
35+
"symfony/http-client": "7.*"
3136
},
3237
"require-dev": {
33-
"phpunit/phpunit": "^9.5.25",
34-
"laravel/pint": "^1.2",
35-
"phpstan/phpstan": "^1.10",
36-
"phpbench/phpbench": "^1.2"
38+
"phpunit/phpunit": "11.*",
39+
"laravel/pint": "1.*",
40+
"phpstan/phpstan": "2.*",
41+
"phpbench/phpbench": "1.*",
42+
"swoole/ide-helper": "6.*"
43+
},
44+
"suggest": {
45+
"ext-swoole": "Required for the Swoole transport implementation",
46+
"ext-sockets": "Required for the Swoole transport implementation"
3747
},
3848
"config": {
3949
"allow-plugins": {

0 commit comments

Comments
 (0)