Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Parametrized test fails with fixture named "request" #611
import pytest @pytest.fixture def request(): return 123 @pytest.mark.parametrize('param', [1, 2, 3]) def test_stuff(request, param): # test stuff assert True
i think "request" is the only real restriction as it serves a purpose for interactions between test or fixture functions and the pytest core. Treating "request" as an illegal name for fixture functions is possible but then again, it's probably used here and there and some might "decorate" the internal request fixture to provide more attributes. Maybe we could generate a warning and then outlaw it with pytest-3.0 or so.