forked from diaspora/diaspora
-
Notifications
You must be signed in to change notification settings - Fork 1
63 lines (62 loc) · 1.57 KB
/
ci.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
51
52
53
54
55
56
57
58
59
60
61
62
63
name: CI
on:
push:
branches:
- develop
- next-minor
- main
- master
pull_request:
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby:
- '3.2'
- '3.3'
db:
- mysql
- postgresql
kind:
- cucumber
- other
env:
DB: ${{ matrix.db }}
RAILS_ENV: test
BUNDLE_WITH: ${{ matrix.db }}
BUNDLE_WITHOUT: development
BUNDLE_FROZEN: true
BUNDLE_DISABLE_SHARED_GEMS: true
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
steps:
- name: Install system dependencies
run: sudo apt update && sudo apt install -y build-essential curl git gsfonts imagemagick libcurl4-openssl-dev libidn11-dev libmagickwand-dev libssl-dev libxml2-dev libxslt1-dev yarnpkg
- name: Start MySQL
run: sudo systemctl start mysql.service
if: matrix.db == 'mysql'
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Prepare
run: script/ci/prepare.sh
- name: Run tests
run: bin/rake --trace ci:${{ matrix.kind }}
- name: Run Jasmine
run: bin/rake jasmine:ci
timeout-minutes: 2
if: matrix.kind == 'other'