Skip to main content

pytest-easy-addoption: Easy way to work with pytest addoption

Project description

pytest-easy-addoption pytest addoption but with power of type annotations and dataclasses.

More documentation here.

An quick example of a usage:

from pytest_easy_addoption import AddOption

class FooBarAddOption(AddOption):
    foo: str
    bar: str = 'BAR'

def pytest_addoption(parser):
from .conftest import FooBarAddOption

def test_example(request):
$ pytest --foo="FOO"
============================= test session starts =============================
collected 1 items FooBarAddOption(foo='FOO', bar='BAR')

=============================  1 passed in 0.03s  =============================

Release history Release notifications

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pytest-easy-addoption, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size pytest-easy-addoption-0.1.1.tar.gz (5.2 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page