summaryrefslogtreecommitdiff
path: root/src/_pytest/main.py
diff options
context:
space:
mode:
authorRan Benita <ran@unusedvar.com>2020-08-21 13:50:13 +0300
committerRan Benita <ran@unusedvar.com>2020-08-24 18:15:11 +0300
commit1b2de81404172d8b48d93e192b59e4c397e08e8d (patch)
treee2acb877e1acb34bd8d3adb1e070ede176bb1c6a /src/_pytest/main.py
parent5356a0979a4b18a111cf5ad4c53484864369652e (diff)
downloadpytest-1b2de81404172d8b48d93e192b59e4c397e08e8d.tar.gz
main: remove unneeded condition in matchnodes
The end result in the `else` branch is the same, but flows naturally.
Diffstat (limited to 'src/_pytest/main.py')
-rw-r--r--src/_pytest/main.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/_pytest/main.py b/src/_pytest/main.py
index d214f0c29..71c230077 100644
--- a/src/_pytest/main.py
+++ b/src/_pytest/main.py
@@ -748,7 +748,7 @@ class Session(nodes.FSCollector):
self.trace("matchnodes", matching, names)
self.trace.root.indent += 1
- if not matching or not names:
+ if not names:
result = matching
else:
name = names[0]