我有一個非常簡單的測試腳本只是爲了學習pytest,tmp.py:pycharm pytestrunner插件管理意想不到的關鍵字參數
def square(x):
return x*x
def test_square():
assert square(4) == 16
使用Pycharm運行此腳本,我已經配置了我的項目設定,即pytest是用作我的默認測試跑步者。當我運行上面的代碼,我得到了以下錯誤:
/Users/mingxiao/webdav_2.7.5/bin/python /Applications/PyCharm.app/helpers/pycharm/pytestrunner.py -p pytest_teamcity /Users/mingxiao/dev/juggernaut/src/integrations/webDAV/demo/tmp.py "-k test_square"
Testing started at 4:41 PM ...
Traceback (most recent call last):
File "/Applications/PyCharm.app/helpers/pycharm/pytestrunner.py", line 51, in <module>
main()
File "/Applications/PyCharm.app/helpers/pycharm/pytestrunner.py", line 20, in main
_pluginmanager = PluginManager(load=True)
TypeError: __init__() got an unexpected keyword argument 'load'
Process finished with exit code 1
我正在PyCharm 3.0專業版,pytest 2.4.2和2.7.5蟒蛇。看來它的PyCharm本身就是造成這個問題的原因。
這是PyCharm與結尾沒有* S *。 –