Pytest在运行测试时在“ collecting ..”语句后停止执行

问题描述

我正在尝试通过pytest执行一些测试。在以前的运行中,pytest能够识别测试并显示错误。清除错误后,pytest启动python引擎,并在如下所示的' collecting ... '语句后突然停止。我找不到原因,因为没有引发任何错误。请帮助。

======================================== test session starts =========================================== 
platform darwin -- Python 2.7.16,pytest-4.6.11,py-1.9.0,pluggy-0.13.1 
rootdir: /Users/user.name/PycharmProjects/ProjectTemplate,inifile: pytest.ini 
plugins: allure-pytest-2.8.18 collecting ... iMAC-Harish:RaftTemplate harish.kannan$

下面是我用来执行测试的命令

python -m pytest

pytest.ini内容

[pytest]
python_files = SuiteRunner.py
python_classes = runTest
python_functions = test_*
log_cli=true
log_format = %(asctime)s %(levelname)s %(message)s
log_date_format = %Y-%m-%d %H:%M:%s

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)