- removes test-models command to reduce binary size - adds integration_test.go with build tag (go test -tags=integration) - tests all provider/model combinations with language/keywords variations - adds testdata/sample.wav for deterministic testing - updates e2e.yml workflow to use go test instead of cli - uses go-version-file in all workflows for consistency
54 lines
1.1 KiB
YAML
54 lines
1.1 KiB
YAML
# .github/workflows/ci.yml
|
|
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main, develop]
|
|
pull_request:
|
|
branches: [main, develop]
|
|
workflow_dispatch: {} # manual trigger
|
|
workflow_call: {} # reusable workflow
|
|
|
|
jobs:
|
|
test:
|
|
name: Test
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: go.mod
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y \
|
|
build-essential \
|
|
pkg-config \
|
|
libasound2-dev \
|
|
libpulse-dev \
|
|
libpipewire-0.3-dev \
|
|
pipewire-bin \
|
|
wl-clipboard \
|
|
wtype
|
|
|
|
- name: Download dependencies
|
|
run: go mod download
|
|
|
|
- name: Run tests
|
|
run: go test -v ./... -short
|
|
|
|
- name: Build binary
|
|
env:
|
|
CGO_ENABLED: 1
|
|
run: go build -o hyprvoice ./cmd/hyprvoice
|
|
|
|
- name: Test binary help
|
|
run: ./hyprvoice --help
|
|
|
|
- name: Test configure command
|
|
run: ./hyprvoice configure --help
|