<div dir="ltr"><div>Hi,</div><div><br></div><div>Suppose I have to test a robot. the robot will be a fixture and as fixture setup the robot gets its firmware downloaded. Multiple firmware versions need to tested.</div><div>Assume the robot fixture scope is &#39;function&#39;. This is not needed based on the example code (which is a simplification).</div><div><div>Some of the tests can be skipped for some firmware versions. I would like to do this using a custom marker.</div><b></b></div><div><b><br></b></div><div>See example code in<a href="https://gist.github.com/lodagro/ae5483215ddd2df791ace7e2d1942318"> gihub gist</a>. <br></div><div><br></div><div>Now I would like to do the following:<br></div><blockquote style="margin-right:0px"><div>- order the test such that a minimal number of firmware downloads are needed (with the current code, there is a max number of fw downloads, remember fixture scope needs to be function)</div><div>- do not download any firmware that does not have related tests</div><div>- implement the skip based on the marker and selected robot firmware</div></blockquote><div><br></div><div>My idea was to do all of this in the pytest_collection_modifyitems method. I found how I can access the marker for each item, but not how can I access robot fixture firmware? So do I need another approach or is it possible to access the robot fixture for each item from pytest_collection_modifyitems ?</div><div><br></div><div>Thanks,</div><div><br></div><div>Wouter</div><b><div><br></div></b><div><b></b></div></div>