Skip to content

Commit 5a7c712

Browse files
authored
chore(ci): use GitHub Actions (#120)
1 parent a672bf3 commit 5a7c712

File tree

2 files changed

+48
-24
lines changed

2 files changed

+48
-24
lines changed

.github/workflows/ci.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: CI
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
CI: true
7+
PGUSER: postgres
8+
PGPASSWORD: postgres
9+
PGHOST: "127.0.0.1"
10+
PGPORT: 5432
11+
TEST_ROOT_DATABASE_URL: postgres://postgres:postgres@localhost:5432/postgres
12+
TEST_DATABASE_URL: postgres://someone:something@localhost:5432/graphile_migrate_test
13+
PGVERSION: 10
14+
15+
jobs:
16+
test:
17+
runs-on: ubuntu-18.04
18+
19+
strategy:
20+
matrix:
21+
node-version: [10.x, 12.x, 14.x]
22+
postgres-version: [10, 11, 12]
23+
24+
services:
25+
postgres:
26+
image: postgres:${{ matrix.postgres-version }}
27+
env:
28+
POSTGRES_USER: postgres
29+
POSTGRES_PASSWORD: postgres
30+
POSTGRES_DB: postgres
31+
ports:
32+
- "0.0.0.0:5432:5432"
33+
# needed because the postgres container does not provide a healthcheck
34+
options:
35+
--health-cmd pg_isready --health-interval 10s --health-timeout 5s
36+
--health-retries 5
37+
38+
steps:
39+
- uses: actions/checkout@v1
40+
- name: Use Node.js ${{ matrix.node-version }}
41+
uses: actions/setup-node@v1
42+
with:
43+
node-version: ${{ matrix.node-version }}
44+
- run: yarn --frozen-lockfile
45+
- run: psql "${TEST_ROOT_DATABASE_URL}" -c "CREATE USER someone WITH LOGIN PASSWORD 'something';"
46+
- run: yarn clean
47+
- run: yarn prepack
48+
- run: yarn jest -i --ci

.travis.yml

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)