Skip to content

Commit 7ed0a3e

Browse files
committed
add tests skeleton
1 parent a082f23 commit 7ed0a3e

File tree

1 file changed

+20
-12
lines changed

1 file changed

+20
-12
lines changed

.github/workflows/tests.yml

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,19 @@ jobs:
1010
tests:
1111
runs-on: ubuntu-latest
1212

13+
rabbitmq:
14+
image: rabbitmq:latest
15+
environment:
16+
RABBITMQ_DEFAULT_USER: guest
17+
RABBITMQ_DEFAULT_PASSWORD: guest
18+
RABBITMQ_DEFAULT_VHOST: /
19+
ports:
20+
- "15671:15671
21+
- "15672:15672
22+
- "5671:5671
23+
- "5672:5672"
24+
25+
1326
strategy:
1427
fail-fast: true
1528
matrix:
@@ -28,19 +41,14 @@ jobs:
2841
php-version: ${{ matrix.php }}
2942
extensions: dom, curl, libxml, mbstring, zip, pcntl
3043
coverage: none
31-
32-
- name: Set up Docker
33-
run: |
34-
sudo rm /usr/local/bin/docker-compose
35-
curl -L https://github.com/docker/compose/releases/download/2.14.2/docker-compose-`uname -s`-`uname -m` > docker-compose
36-
chmod +x docker-compose
37-
sudo mv docker-compose /usr/local/bin
38-
39-
- name: Start Docker container
40-
run: docker-compose up -d rabbitmq
44+
tools: composer:v2
4145

4246
- name: Install dependencies
43-
run: composer update --prefer-dist --no-interaction --no-progress
47+
uses: nick-fields/retry@v2
48+
with:
49+
timeout_minutes: 5
50+
max_attempts: 5
51+
command: composer update --${{ matrix.stability }} --prefer-dist --no-interaction --no-progress
4452

4553
- name: Execute tests
46-
run: sleep 10 && vendor/bin/phpunit --verbose
54+
run: vendor/bin/phpunit --verbose

0 commit comments

Comments
 (0)