Make scripts under /test/srt as unit tests (#875)

This commit is contained in:
Ying Sheng
2024-08-01 14:34:55 -07:00
committed by GitHub
parent e4d3333c6c
commit 72b6ea88b4
18 changed files with 353 additions and 212 deletions

View File

@@ -20,8 +20,6 @@ concurrency:
jobs:
unit-test:
runs-on: self-hosted
env:
CUDA_VISIBLE_DEVICES: 6
steps:
- name: Checkout code
@@ -30,6 +28,7 @@ jobs:
- name: Install dependencies
run: |
cd /data/zhyncs/venv && source ./bin/activate && cd -
pip cache purge
pip install --upgrade pip
pip install -e "python[all]"
@@ -39,6 +38,14 @@ jobs:
- name: Test OpenAI Backend
run: |
cd /data/zhyncs/venv && source ./bin/activate && cd -
cd test/lang
export OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }}
cd test/lang
python3 test_openai_backend.py
- name: Test SRT Backend
run: |
cd /data/zhyncs/venv && source ./bin/activate && cd -
cd test/lang
python3 test_srt_backend.py