【发布时间】:2015-08-03 14:54:13
【问题描述】:
是否可以在 Pytest 夹具中获取参数 ID?
import pytest
@pytest.fixture(
params = ['a', 'b', 'c'],
ids = ['x', 'y', 'z'])
def foo(request):
myParam = request.param
myID = "How do I get the current ID?"
【问题讨论】: