@@ -227,13 +227,19 @@ def generate_filled_checklist(self, eip: int, output_dir: Path) -> Path:
227227
228228 return output_dir
229229
230+ @pytest .hookimpl (tryfirst = True )
231+ def pytest_runtestloop (self , session ):
232+ """Skip test execution, only generate checklists."""
233+ session .testscollected = 0
234+ return True
235+
230236 def pytest_collection_modifyitems (self , config : pytest .Config , items : List [pytest .Item ]):
231237 """Collect checklist markers during test collection."""
232238 for item in items :
233239 eip , eip_path = self .extract_eip_from_path (Path (item .location [0 ]))
234240 if eip_path is not None and eip is not None :
235241 self .eip_paths [eip ] = eip_path
236- if item .get_closest_marker ("derived_test" ):
242+ if item .get_closest_marker ("derived_test" ) or item . get_closest_marker ( "skip" ) :
237243 continue
238244 self .collect_from_item (item , eip )
239245
@@ -247,6 +253,9 @@ def pytest_collection_modifyitems(self, config: pytest.Config, items: List[pytes
247253
248254 checklist_props = {}
249255
256+ if not self .eip_checklist_items :
257+ pytest .exit ("\n No EIPs found with checklist markers." , returncode = pytest .ExitCode .OK )
258+
250259 # Generate a checklist for each EIP
251260 for eip in sorted (self .eip_checklist_items .keys ()):
252261 # Skip if specific EIPs were requested and this isn't one of them
@@ -267,7 +276,7 @@ def pytest_collection_modifyitems(self, config: pytest.Config, items: List[pytes
267276 )
268277 else :
269278 checklist_path = self .generate_filled_checklist (eip , checklist_output )
270- print (f"Generated EIP-{ eip } checklist: { checklist_path } " )
279+ print (f"\n Generated EIP-{ eip } checklist: { checklist_path } " )
271280
272281 if checklist_doc_gen :
273282 config .checklist_props = checklist_props # type: ignore
0 commit comments