-
Notifications
You must be signed in to change notification settings - Fork 127
50 lines (50 loc) · 1.33 KB
/
unit-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
name: Unit tests
on:
pull_request:
push:
branches:
- qa/**
- stable/**
jobs:
unit-tests:
runs-on: ubuntu-20.04
name: PHP 7.4
env:
COMPOSE_FILE: ${{ github.workspace }}/docker/docker-compose.dev.yml
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Start containerized services
run: |
sudo sysctl -w vm.max_map_count=262144
docker-compose up -d percona elasticsearch
- name: Setup PHP 7.4
uses: shivammathur/setup-php@v2
with:
php-version: 7.4
coverage: none
extensions: apcu
- name: Cache dependencies
uses: actions/cache@v3
with:
path: ~/.composer/cache/files
key: 20.04-7.4-composer-${{ hashFiles('composer.lock') }}
- name: Install dependencies
run: composer install
- name: Wait for containerized services
run: sleep 10
- name: Run the installer
run: |
php symfony tools:install \
--database-host=127.0.0.1 \
--database-port=63003 \
--database-name=atom \
--database-user=atom \
--database-password=atom_12345 \
--search-host=127.0.0.1 \
--search-port=63002 \
--search-index=atom \
--demo \
--no-confirmation
- name: Run tests
run: composer test