databag/.github/workflows/ci.yml

64 lines
1.1 KiB
YAML
Raw Normal View History

2022-12-31 18:23:32 +00:00
name: CI
2022-07-01 22:04:44 +00:00
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
2022-12-31 18:23:32 +00:00
CI:
2022-07-01 22:04:44 +00:00
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
2022-09-02 04:09:40 +00:00
- name: Setup Node
2022-09-02 04:14:50 +00:00
uses: actions/setup-node@v3
with:
node-version: 16
- name: Build React
2022-09-02 04:09:40 +00:00
run: |
2022-09-02 04:18:20 +00:00
npm install --global yarn
2022-09-02 04:14:50 +00:00
cd net/web
yarn install
yarn build
2022-07-01 22:04:44 +00:00
2022-09-02 04:09:40 +00:00
- name: Setup Go
2022-07-01 22:04:44 +00:00
uses: actions/setup-go@v3
with:
2024-01-14 07:45:31 +00:00
go-version: 1.18.10
2022-07-01 22:04:44 +00:00
2022-09-02 04:14:50 +00:00
- name: Build Go
2022-07-01 22:07:30 +00:00
run: |
cd net/server
go build databag
2022-12-31 18:05:28 +00:00
- name: Go Test
2022-07-01 22:07:30 +00:00
run: |
cd net/server
go test -v ./...
2022-12-31 18:05:28 +00:00
- name: Jest Setup
2022-12-31 08:01:43 +00:00
uses: actions/setup-node@v3
with:
node-version: 18
2022-12-31 18:05:28 +00:00
- name: Jest ReactJs
run: |
cd net/web
2023-01-28 05:19:04 +00:00
yarn jest --silent
2022-12-31 18:05:28 +00:00
2022-12-31 18:12:29 +00:00
- name: Jest ReactNative
run: |
cd app/mobile
2022-12-31 18:17:27 +00:00
yarn install
2022-12-31 18:12:29 +00:00
yarn jest
2022-09-02 05:45:17 +00:00
- name: Export
2022-10-26 21:02:15 +00:00
uses: actions/upload-artifact@v3
2022-09-02 05:45:17 +00:00
with:
name: webapp
path: net/web/build/*