From 5187869cfb87f05d57cc176144aa970c66376748 Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Thu, 6 Jun 2024 11:26:27 -0400 Subject: [PATCH] Remove empty else block (implicit is better than explicit). --- src/_pytest/doctest.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/_pytest/doctest.py b/src/_pytest/doctest.py index 4eb2c1991..23ad7a7a9 100644 --- a/src/_pytest/doctest.py +++ b/src/_pytest/doctest.py @@ -559,9 +559,6 @@ class DoctestModule(Module): # Type ignored because this is a private function. return super()._from_module(module, object) # type: ignore[misc] - else: # pragma: no cover - pass - try: module = self.obj except Collector.CollectError: