跳到主要内容
版本:Current

测试与检查

框架是 Django TestCase,命令:

python manage.py test --verbosity=2
python manage.py check

现有测试文件:

  • accounts/tests.py、tests_application_profile.py、tests_activation_codes.py
  • recruitment/tests.py
  • mailing/tests.py
  • classroom/tests.py、files/tests.py、services/tests.py、core/tests.py、core/tests_admin_users.py
  • treasury/tests.py(覆盖较薄)

改招新状态机、权限、邮件时必须加断言。仓库里可能有 .pytest_cache,但没有 pytest 配置;不要以为 pytest 是官方入口。