mirror of
https://github.com/Wei-Shaw/sub2api.git
synced 2026-09-24 16:05:44 +08:00
Merge upstream main branch changes including: - OpenAI Codex support and websearch adaptation - API key rate limit auto-reset fix - golangci-lint v2.11 upgrade for Go 1.26 compatibility - Go 1.26.1 stdlib security fixes - Empty stream failover fix - CCSwitch import improvements - API key credentials preserve existing fields - Usage query rate limit optimization - Setup Token real utilization fix Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
49 lines
1.1 KiB
YAML
49 lines
1.1 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
- uses: actions/setup-go@v6
|
|
with:
|
|
go-version-file: backend/go.mod
|
|
check-latest: false
|
|
cache: true
|
|
cache-dependency-path: backend/go.sum
|
|
- name: Verify Go version
|
|
run: |
|
|
go version | grep -q 'go1.26.1'
|
|
- name: Unit tests
|
|
working-directory: backend
|
|
run: make test-unit
|
|
- name: Integration tests
|
|
working-directory: backend
|
|
run: make test-integration
|
|
|
|
golangci-lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
- uses: actions/setup-go@v6
|
|
with:
|
|
go-version-file: backend/go.mod
|
|
check-latest: false
|
|
cache: true
|
|
cache-dependency-path: backend/go.sum
|
|
- name: Verify Go version
|
|
run: |
|
|
go version | grep -q 'go1.26.1'
|
|
- name: golangci-lint
|
|
uses: golangci/golangci-lint-action@v9
|
|
with:
|
|
version: v2.11
|
|
args: --timeout=30m
|
|
working-directory: backend |