config.yaml 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. # 浏览器配置
  2. browser:
  3. type: chrome
  4. headless: false
  5. implicit_wait: 10
  6. explicit_wait: 30
  7. poll_frequency: 0.5
  8. window_size: [1920, 1080]
  9. # 数据库配置
  10. database:
  11. driver: mysql
  12. host: localhost
  13. port: 3306
  14. name: test_automation
  15. user: root
  16. password: password
  17. echo: false
  18. pool_size: 5
  19. max_overflow: 10
  20. pool_timeout: 30
  21. pool_recycle: 3600
  22. # API配置
  23. api:
  24. base_url: https://api.example.com
  25. timeout: 30
  26. retry_attempts: 3
  27. retry_delay: 1
  28. # 邮件配置
  29. email:
  30. smtp_server: smtp.gmail.com
  31. smtp_port: 587
  32. username: your_email@gmail.com
  33. password: your_app_password
  34. recipients:
  35. - recipient1@example.com
  36. - recipient2@example.com
  37. # 报告配置
  38. report:
  39. email_recipients:
  40. - team@example.com
  41. email_subject: "自动化测试报告 - {date}"
  42. report_dir: resources/reports
  43. # 测试数据配置
  44. test_data:
  45. paths:
  46. - resources/test_data/json
  47. - resources/test_data/excel
  48. default_format: json
  49. # 环境配置
  50. environment: dev
  51. # 日志配置
  52. logging:
  53. level: INFO
  54. format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s"
  55. file: resources/logs/automation.log
  56. max_size: 10485760 # 10MB
  57. backup_count: 5