简体   繁体   English

Pycharm 3.4.1 CE doctests:无法运行目录

[英]Pycharm 3.4.1 CE doctests: can't run for directory

When I try to run all doctests for directory I receive 当我尝试运行目录的所有doctest时,我收到

/usr/bin/python3.4 /home/d9k/soft/pycharm-community-3.4.1/helpers/pycharm/docrunner.py /home/d9k/pr/bkuppr/
Testing started at 12:05 AM ...
usage: .........
docrunner.py: error: invalid choice: '/home/d9k/pr/bkuppr/' (choose from 'run', 'restore', 'edit', 'test') ......
Empty test suite.

When I run doctests for one specific file docrunner find them and execute correctly. 当我为一个特定文件docrunner运行doctest时,找到它们并正确执行。

How to setup doctests for running all tests from folder properly? 如何设置doctests以正确运行文件夹中的所有测试?

OK, there was a bug in module docrunner.py: some commands were not in 好的,模块docrunner.py中存在一个错误:某些命令不在

if __name__ == "__main__":

block, so they were executed and crushed tests run. 块,因此它们被执行并运行压碎的测试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM