pytest-dev / pytest-repeat

pytest plugin for repeating test execution
https://pypi.python.org/pypi/pytest-repeat/
Other
172 stars 27 forks source link

Pass a type instead of string to parser.addoption #11

Closed The-Compiler closed 8 years ago

The-Compiler commented 8 years ago

Otherwise we get this DeprecationWarning with pytest 3.0:

  [...]
  File ".../pytest_repeat.py", line 16, in pytest_addoption
    help='Number of times to repeat each test')
  File ".../_pytest/config.py", line 482, in addoption
    self._anonymous.addoption(*opts, **attrs)
  File ".../_pytest/config.py", line 708, in addoption
    option = Argument(*optnames, **attrs)
  File ".../_pytest/config.py", line 609, in __init__
    stacklevel=3)
DeprecationWarning: type argument to addoption() is a string 'int'. For parsearg this should be a type. (options: ('--count',))
tomviner commented 8 years ago

:+1:

The-Compiler commented 8 years ago

We plan to release 3.0 somewhen next week, would be great if there was a new pytest-repeat release with this in before that :wink:

davehunt commented 8 years ago

I've released 0.4.0 here: https://pypi.python.org/pypi/pytest-repeat/0.4.0

tomviner commented 8 years ago

@davehunt happy to be a co-releaser if that's helpful for the future :-)

davehunt commented 8 years ago

@tomviner what's your PyPI username?

tomviner commented 8 years ago

@davehunt it's tomviner

davehunt commented 8 years ago

@tomviner you're now a maintainer. :)

tomviner commented 8 years ago

great, thanks @davehunt