def test(ctx, watch=False, last_failing=False):
"""Run the tests.
Note: --watch requires pytest-xdist to be installed.
"""
import pytest
flake(ctx)
args = []
if watch:
args.append('-f')
if last_failing:
args.append('--lf')
retcode = pytest.main(args)
sys.exit(retcode)
评论列表
文章目录