refactor: 模块化架构重构 & 完善测试与文档体系
- 架构重构:拆分为 routes/services/repositories/security 分层结构 - 新增测试:添加完整的单元测试套件(烟雾测试/核心功能/错误处理等) - 完善文档:添加开发者指南、运行验证、回归清单、性能基线等文档 - 前后端分离:静态资源独立,模板组件化 - CI/CD:添加 GitHub Actions 自动化测试 - Docker 优化:添加健康检查,修复调度器启动问题 - 配置增强:支持 SCHEDULER_AUTOSTART 环境变量 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
14614249f7
commit
192240436d
99 files changed
+19956
-9444
No files matched your search
@@ -0,0 +1,48 @@
|
||||
name: Python Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "main", "master" ]
|
||||
paths:
|
||||
- "**.py"
|
||||
- "requirements.txt"
|
||||
- "tests/**"
|
||||
- ".github/workflows/python-tests.yml"
|
||||
pull_request:
|
||||
paths:
|
||||
- "**.py"
|
||||
- "requirements.txt"
|
||||
- "tests/**"
|
||||
- ".github/workflows/python-tests.yml"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
tests:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: [ "3.11", "3.12", "3.13" ]
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
python -m pip install -r requirements.txt
|
||||
|
||||
- name: Syntax check
|
||||
run: |
|
||||
python -m py_compile web_outlook_app.py
|
||||
python -m py_compile outlook_mail_reader.py
|
||||
|
||||
- name: Run unit tests
|
||||
run: python -m unittest discover -s tests -v
|
||||
|
||||
Reference in new issue
Block a user