mirror of
https://github.com/shareAI-lab/analysis_claude_code.git
synced 2026-02-04 13:16:37 +08:00
45 lines
985 B
YAML
45 lines
985 B
YAML
name: Test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
unit-test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v6
|
|
with:
|
|
python-version: "3.11"
|
|
|
|
- name: Install dependencies
|
|
run: pip install anthropic python-dotenv
|
|
|
|
- name: Run unit tests
|
|
run: python tests/test_unit.py
|
|
|
|
integration-test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v6
|
|
with:
|
|
python-version: "3.11"
|
|
|
|
- name: Install dependencies
|
|
run: pip install anthropic python-dotenv openai
|
|
|
|
- name: Run integration tests
|
|
env:
|
|
TEST_API_KEY: ${{ secrets.TEST_API_KEY }}
|
|
TEST_BASE_URL: ${{ secrets.TEST_BASE_URL }}
|
|
TEST_MODEL: ${{ secrets.TEST_MODEL }}
|
|
run: python tests/test_agent.py
|