dbgate/.github/workflows/run-tests.yaml

83 lines
2.0 KiB
YAML
Raw Normal View History

2021-05-30 09:00:32 +00:00
name: Run tests
2021-05-27 09:28:20 +00:00
on:
push:
branches:
- master
2021-09-06 16:25:34 +00:00
- develop
2021-05-27 09:28:20 +00:00
jobs:
2021-05-31 16:38:16 +00:00
test-runner:
2021-05-27 09:28:20 +00:00
runs-on: ubuntu-latest
2024-05-08 17:00:28 +00:00
container: node:18
2021-05-27 09:28:20 +00:00
steps:
- name: Context
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: echo "$GITHUB_CONTEXT"
2021-09-28 06:15:08 +00:00
- uses: actions/checkout@v2
2021-05-27 09:28:20 +00:00
with:
fetch-depth: 1
- name: yarn install
run: |
yarn install
2021-05-30 09:00:32 +00:00
- name: Integration tests
2021-05-27 09:28:20 +00:00
run: |
cd integration-tests
2021-05-27 13:13:14 +00:00
yarn test:ci
2021-05-28 13:21:19 +00:00
# yarn wait:ci
2021-05-30 09:00:32 +00:00
- name: Filter parser tests
2021-05-30 09:07:32 +00:00
if: always()
2021-05-30 09:00:32 +00:00
run: |
cd packages/filterparser
yarn test:ci
2022-07-31 06:49:25 +00:00
- name: Datalib (perspective) tests
if: always()
run: |
cd packages/datalib
yarn test:ci
2021-05-28 13:10:02 +00:00
- uses: tanmen/jest-reporter@v1
2021-05-28 13:29:20 +00:00
if: always()
2021-05-28 13:12:06 +00:00
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
result-file: integration-tests/result.json
2021-05-30 09:07:32 +00:00
action-name: Integration tests
2021-05-30 09:00:32 +00:00
- uses: tanmen/jest-reporter@v1
if: always()
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
result-file: packages/filterparser/result.json
2021-05-31 16:38:16 +00:00
action-name: Filter parser test results
2022-07-31 06:49:25 +00:00
- uses: tanmen/jest-reporter@v1
if: always()
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
result-file: packages/datalib/result.json
action-name: Datalib (perspectives) test results
2021-05-27 09:28:20 +00:00
services:
postgres:
image: postgres
2021-05-27 10:04:13 +00:00
env:
2021-05-27 09:28:20 +00:00
POSTGRES_PASSWORD: Pwd2020Db
2021-05-27 10:44:11 +00:00
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
2021-05-27 09:28:20 +00:00
2021-05-27 13:51:54 +00:00
mysql:
2021-05-27 13:59:57 +00:00
image: mysql:8.0.18
2021-05-27 13:51:54 +00:00
env:
MYSQL_ROOT_PASSWORD: Pwd2020Db
2021-05-27 09:28:20 +00:00
2021-05-27 11:07:58 +00:00
mssql:
image: mcr.microsoft.com/mssql/server
env:
ACCEPT_EULA: Y
SA_PASSWORD: Pwd2020Db
MSSQL_PID: Express
2021-05-27 09:28:20 +00:00
2021-05-27 13:13:14 +00:00
# cockroachdb:
# image: cockroachdb/cockroach