[wingide-users] Wing Pytest Invalid Argument Error?

Karl Chester karl_chester at hotmail.com
Tue Aug 25 12:37:45 EDT 2015


Trying to run a py.test unit test, and now getting an argument error.I was running tests fine early last week, and now I am seeing this strange argument error. I think it could be environment related, but I'm not sure what to change. Hopefully I am including enough information in this post, but please ask if I am not.
1. I have setup a project in Wing and used files that I checked out from my companies git repository.2. I setup the default testing framework in the project properties to pytest.3. I open the file I want to run test in, in Wing, and then I select 'add current file' from the testing menu option at the top of wing.4. In the testing tab of the debug area at the bottom of wing IDE, I right mouse click on the newly added filename and choose 'debug test' from the popup menu.5. I now get a pytest assertion error in main.py.
File "C:\Program Files (x86)\Wing IDE 5.1\src\testing\runners\run_pytest_xml.py", line 353, in <module>
  main(list(sys.argv))
File "C:\Program Files (x86)\Wing IDE 5.1\src\testing\runners\run_pytest_xml.py", line 312, in main
  RunInSingleDir(module_names, xmlout, module_dir)
File "C:\Program Files (x86)\Wing IDE 5.1\src\testing\runners\run_pytest_xml.py", line 344, in RunInSingleDir
  pytest.main(args=['-s', '-p', 'no:terminal', '--tb=native'] + module_fullpath_list, plugins=[plugin])
File "C:\Python27\Lib\site-packages\_pytest\config.py", line 41, in main
  return config.hook.pytest_cmdline_main(config=config)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 413, in __call__
  return self._docall(methods, kwargs)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 424, in _docall
  res = mc.execute()
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 315, in execute
  res = method(**kwargs)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 116, in pytest_cmdline_main
  return wrap_session(config, _main)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 84, in wrap_session
  doit(config, session)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 121, in _main
  config.hook.pytest_collection(session=session)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 413, in __call__
  return self._docall(methods, kwargs)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 424, in _docall
  res = mc.execute()
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 315, in execute
  res = method(**kwargs)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 125, in pytest_collection
  return session.perform_collect()
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 545, in perform_collect
  items = self._perform_collect(args, genitems)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 565, in _perform_collect
  rep = collect_one_node(self)
File "C:\Python27\Lib\site-packages\_pytest\runner.py", line 401, in collect_one_node
  rep = ihook.pytest_make_collect_report(collector=collector)
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 166, in call_matching_hooks
  return hookmethod.pcall(plugins, **kwargs)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 417, in pcall
  return self._docall(methods, kwargs)
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 424, in _docall
  res = mc.execute()
File "C:\Python27\Lib\site-packages\_pytest\core.py", line 315, in execute
  res = method(**kwargs)
File "C:\Python27\Lib\site-packages\_pytest\runner.py", line 273, in pytest_make_collect_report
  call = CallInfo(collector._memocollect, "memocollect")
File "C:\Python27\Lib\site-packages\_pytest\runner.py", line 139, in __init__
  self.result = func()
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 438, in _memocollect
  return self._memoizedcall('_collected', lambda: list(self.collect()))
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 315, in _memoizedcall
  res = function()
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 438, in <lambda>
  return self._memoizedcall('_collected', lambda: list(self.collect()))
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 589, in collect
  for x in self._collect(arg):
File "C:\Python27\Lib\site-packages\_pytest\main.py", line 602, in _collect
  assert not names, "invalid arg %r" %(arg,)

_pytest.assertion.reinterpret.AssertionError: invalid arg 'c:\\Turtle\\test-automation::web_driver::tests::<compnay>::<company>_submission_tests' 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://wingware.com/pipermail/wingide-users/attachments/20150825/774fc40d/attachment.html>


More information about the wingide-users mailing list