PyCharm/Python。代码不运行。立即接收“正在完成进程,退出代码为0”

2024-06-01 08:29:32 发布

您现在位置:Python中文网/ 问答频道 /正文

我最近换了我的工作站,重新安装了我所有的环境在Fedora25上。 当试图运行我的项目的任何部分(我运行PyTest测试)时,我总是在debug中得到“Process finished with exit code 0”消息。

下面是完整的调试消息:

    /usr/bin/python2.7 /usr/share/java/pycharm-community/helpers/pydev/pydevd.py --multiproc --qt-support --client 127.0.0.1 --port 46537 --file /home/pavel/Documents/integration_tests/cfme/tests/containers/test_containers_default_project_replicators.py
warning: Debugger speedups using cython not found. Run '"/usr/bin/python2.7" "/usr/share/java/pycharm-community/helpers/pydev/setup_cython.py" build_ext --inplace' to build.
pydev debugger: process 10166 is connecting

Connected to pydev debugger (build 163.10154.50)
/home/pavel/Documents/integration_tests/utils/log.py:222: UserWarning: clearing configuration is bad
  del(conf['env'])

我试图运行的项目实际上是开源的,这里是供参考的: https://github.com/ManageIQ/integration_tests


Tags: 项目pycommunitybuild消息sharehomebin
1条回答
网友
1楼 · 发布于 2024-06-01 08:29:32

好的,问题是我试图将其作为Python运行/调试配置而不是Py.test运行/调试配置运行。

How do I configure PyCharm to run py.test tests?

请转到文件| Settings | Tools | Python Integrated Tools并将默认测试运行程序更改为py.test。然后您将得到py.test选项来创建测试,而不是unittest选项。

相关问题 更多 >