mirror of
https://github.com/hay-kot/homebox.git
synced 2024-11-16 13:48:44 +00:00
7ccd48ad79
* do end-to-end testing * set node version * build then start * remove test restrictions * panic if mime type fails * use timeout
50 lines
1.1 KiB
YAML
50 lines
1.1 KiB
YAML
version: "3"
|
|
|
|
tasks:
|
|
api:
|
|
cmds:
|
|
- cd backend/app/api/ && swag fmt
|
|
- cd backend/app/api/ && swag init --dir=./,../../internal,../../pkgs,../../ent
|
|
# - |
|
|
# npx swagger-typescript-api \
|
|
# --path ./backend/app/api/docs/swagger.json \
|
|
# --output ./client/auto-client \
|
|
# --module-name-first-tag \
|
|
# --modular
|
|
- cd backend && go run ./app/api/ {{.CLI_ARGS}}
|
|
silent: false
|
|
sources:
|
|
- ./backend/**/*.go
|
|
|
|
api:build:
|
|
cmds:
|
|
- cd backend && go build ./app/api/
|
|
silent: true
|
|
|
|
api:test:
|
|
cmds:
|
|
- cd backend && go test ./app/api/
|
|
silent: true
|
|
|
|
api:coverage:
|
|
cmds:
|
|
- cd backend && go test -race -coverprofile=coverage.out -covermode=atomic ./app/... ./internal/... ./pkgs/... -v -cover
|
|
silent: true
|
|
|
|
test:integration:
|
|
cmds:
|
|
- cd backend && go build ./app/api
|
|
- backend/api &
|
|
- sleep 5
|
|
- cd frontend && pnpm run test:ci
|
|
silent: true
|
|
|
|
docker:build:
|
|
cmds:
|
|
- cd backend && docker-compose up --build
|
|
silent: true
|
|
|
|
generate:types:
|
|
cmds:
|
|
- cd backend && go run ./app/generator
|
|
silent: true
|