-
Notifications
You must be signed in to change notification settings - Fork 4
64 lines (54 loc) · 1.48 KB
/
tests.yml
File metadata and controls
64 lines (54 loc) · 1.48 KB
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
name: "Tests"
on: [pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Run Unit Tests
run: |
docker run --rm \
-v $PWD:/app \
-w /app \
phpswoole/swoole:5.1.2-php8.3-alpine \
sh -c "
apk update && \
apk add zip unzip && \
composer install --profile --ignore-platform-reqs && \
composer test -- --testsuite=unit
"
executor-tests:
name: Executor Tests
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Start Test Stack
run: |
docker compose build
docker compose up -d --wait --wait-timeout 300
- name: Doctor
run: |
docker compose logs
docker ps
docker network ls
- name: Run Executor Tests
run: |
docker run --rm \
-v $PWD:/app \
-v /tmp:/tmp \
-v /var/run/docker.sock:/var/run/docker.sock \
--network executor_runtimes \
-w /app \
phpswoole/swoole:5.1.2-php8.3-alpine \
sh -c "
apk update && \
apk add docker-cli zip unzip && \
composer install --profile --ignore-platform-reqs && \
composer test -- --testsuite=e2e
"