pydev鼻子测试测试运行 [英] pydev nosetests test run

查看:135
本文介绍了pydev鼻子测试测试运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎是一个愚蠢的问题,但我一直无法弄清楚...

Seems like a silly question but I've been unable to figure it out...

我想使用eclipse/pyunit来运行我的所有测试.我已将测试运行器配置为鼻子测试运行器.

I'd like to use eclipse/pyunit to run all my tests. I've configured the test runner to be the nose test runner.

现在我想让pyunit使用鼻子

Now I'd like for pyunit to use nose

推荐答案

您可以右键单击某个文件夹/文件,然后选择运行方式">"Python unittest";如果您在编辑器中打开了该文件,则可以使用"Ctrl + F9'运行测试(甚至过滤以选择要运行的测试).

You can right-click a folder/file and choose Run as > Python unittest or if you have the file open in an editor, you can use 'Ctrl+F9' to run the tests (and even filter to select the test(s) you want to run).

注意:要使用鼻子,您必须在首选项(窗口>首选项> pydev> pyunit)中选择鼻子测试运行器-如果您使用py.test运行器,则也是如此(但是请注意,如果您使用常规的单元测试,则默认运行程序应该可以正常运行).

Note: for this to work with nose you have to select the nose test runner in the preferences (window > preferences > pydev > pyunit) -- and the same is true if you're using the py.test runner (but note that if you're using regular unittest tests, the default runner should work fine).

这篇关于pydev鼻子测试测试运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆