/pytest-crontab

register crontab task for pytest

Primary LanguagePythonMIT LicenseMIT

pytest-crontab

Pytest注册crontab 任务


如何使用

  1. 安装 pytest-crontab
pip install pytest-crontab
  1. 使用方法

或命令行传入

$ pytest --crontab='*/1 * * * *'

注册在crontab中的任务默认使用pytest .运行所有

crontab -l 查看任务

*/1 * * * * cd /root; pytest . >>pytest.log

目前仅支持CentOS