

def given(name, fixture=None, converters=None, scope='function', target_fixture=None):
    "Given step decorator.\n\n    :param name: Given step name.\n    :param fixture: Optional name of the fixture to reuse.\n    :param converters: Optional `dict` of the argument or parameter converters in form\n                       {<param_name>: <converter function>}.\n    :scope: Optional fixture scope\n    :param target_fixture: Target fixture name to replace by steps definition function\n    :raises: StepError in case of wrong configuration.\n    :note: Can't be used as a decorator when the fixture is specified.\n    "
    if (fixture is not None):
        module = get_caller_module()

        def step_func(request):
            return request.getfuncargvalue(fixture)
        step_func.step_type = GIVEN
        step_func.converters = converters
        step_func.__name__ = name
        step_func.fixture = fixture
        func = pytest.fixture(scope=scope)((lambda : step_func))
        func.__doc__ = 'Alias for the "{0}" fixture.'.format(fixture)
        (_, name) = parse_line(name)
        contribute_to_module(module, get_step_fixture_name(_, GIVEN), func)
        return _not_a_fixture_decorator
    return _step_decorator(GIVEN, name, converters=converters, scope=scope, target_fixture=target_fixture)

dataset/ETHPy150Open pytest-dev/pytest-bdd/pytest_bdd/steps.py given/VarMisuse@132/360 `name`->`_`