mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-05 00:40:13 +08:00
feat: preserve TypeScript engine migration and workspace updates
This commit is contained in:
53
.github/workflows/tests.yml
vendored
53
.github/workflows/tests.yml
vendored
@@ -16,6 +16,7 @@ on:
|
||||
- "requirements.txt"
|
||||
- "pyproject.toml"
|
||||
- "web/**"
|
||||
- "packages/chat-engine/**"
|
||||
- ".github/workflows/tests.yml"
|
||||
pull_request:
|
||||
branches:
|
||||
@@ -29,9 +30,56 @@ on:
|
||||
- "requirements.txt"
|
||||
- "pyproject.toml"
|
||||
- "web/**"
|
||||
- "packages/chat-engine/**"
|
||||
- ".github/workflows/tests.yml"
|
||||
|
||||
jobs:
|
||||
chat-engine:
|
||||
name: Experimental TypeScript Chat Engine
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: "22"
|
||||
cache: npm
|
||||
cache-dependency-path: packages/chat-engine/package-lock.json
|
||||
- name: Check scheduler contracts and dependency boundaries
|
||||
working-directory: packages/chat-engine
|
||||
run: npm ci && npm test
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.11"
|
||||
- name: Install compatibility adapters
|
||||
run: pip install -r requirements/server.txt -r requirements/partners.txt pytest pytest-asyncio
|
||||
- name: Create synthetic model configuration
|
||||
run: |
|
||||
mkdir -p data/user/settings
|
||||
cp tests/fixtures/ci_model_catalog.json data/user/settings/model_catalog.json
|
||||
- name: Exercise chat and partner behavior through TypeScript
|
||||
env:
|
||||
DEEPTUTOR_CHAT_ENGINE: typescript
|
||||
PYTHONPATH: ${{ github.workspace }}
|
||||
run: |
|
||||
pytest -q tests/agents/chat tests/runtime/test_ts_engine.py \
|
||||
tests/services/partners/test_partner_runtime.py \
|
||||
tests/capabilities/test_partner_group_capability.py \
|
||||
tests/capabilities/test_mastery_loop_pipeline.py
|
||||
- name: Exercise the Python reference and durable event subscriptions
|
||||
env:
|
||||
DEEPTUTOR_CHAT_ENGINE: python
|
||||
PYTHONPATH: ${{ github.workspace }}
|
||||
run: |
|
||||
pytest -q tests/agents/chat/test_agent_loop.py \
|
||||
tests/runtime/coordination/test_event_notifications.py \
|
||||
tests/app/test_turn_application_service.py
|
||||
- name: Exercise native model, history, tool boundaries and lazy API admission
|
||||
env:
|
||||
PYTHONPATH: ${{ github.workspace }}
|
||||
run: |
|
||||
pytest -q tests/runtime/test_native_engine.py \
|
||||
tests/api/test_router_loader.py
|
||||
|
||||
lint:
|
||||
name: Lint and Format
|
||||
runs-on: ubuntu-latest
|
||||
@@ -291,7 +339,7 @@ jobs:
|
||||
test-summary:
|
||||
name: Test Summary
|
||||
runs-on: ubuntu-latest
|
||||
needs: [lint, web-tests, multi-worker-web, import-check, python-tests]
|
||||
needs: [chat-engine, lint, web-tests, multi-worker-web, import-check, python-tests]
|
||||
if: always()
|
||||
|
||||
steps:
|
||||
@@ -301,6 +349,7 @@ jobs:
|
||||
echo "" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Check | Status |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "|-------|--------|" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| TypeScript chat engine | ${{ needs.chat-engine.result == 'success' && '✅ Passed' || '❌ Failed' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Lint and format | ${{ needs.lint.result == 'success' && '✅ Passed' || '❌ Failed' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Web node tests | ${{ needs.web-tests.result == 'success' && '✅ Passed' || '❌ Failed' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Four-worker browser acceptance | ${{ needs.multi-worker-web.result == 'success' && '✅ Passed' || needs.multi-worker-web.result == 'skipped' && '⏭️ Fixture not configured' || '❌ Failed' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
@@ -308,5 +357,5 @@ jobs:
|
||||
echo "| Python tests (3.11/3.12/3.13/3.14) | ${{ needs.python-tests.result == 'success' && '✅ Passed' || '❌ Failed' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
|
||||
- name: Fail if tests failed
|
||||
if: needs.lint.result == 'failure' || needs.web-tests.result == 'failure' || needs.multi-worker-web.result == 'failure' || needs.import-check.result == 'failure' || needs.python-tests.result == 'failure'
|
||||
if: needs.chat-engine.result == 'failure' || needs.lint.result == 'failure' || needs.web-tests.result == 'failure' || needs.multi-worker-web.result == 'failure' || needs.import-check.result == 'failure' || needs.python-tests.result == 'failure'
|
||||
run: exit 1
|
||||
|
||||
Reference in New Issue
Block a user