File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -150,15 +150,17 @@ def _add_end_lineno_if_missing(tree, line_count: int):
150
150
setattr (prev_node , "end_lineno" , line_count ) # noqa: B010
151
151
152
152
153
- def _find_marks (func_node : ast .FunctionDef ) -> Set [str ]:
153
+ def _find_marks (func_node : Union [ ast .FunctionDef , ast . AsyncFunctionDef ] ) -> Set [str ]:
154
154
return {
155
155
name .split ("." , 2 )[2 ]
156
156
for name , _ in _iter_func_decorators (func_node )
157
157
if name .startswith ("pytest.mark." )
158
158
}
159
159
160
160
161
- def _iter_func_decorators (func_node : ast .FunctionDef ) -> Iterator [Tuple [str , ast .AST ]]:
161
+ def _iter_func_decorators (
162
+ func_node : Union [ast .FunctionDef , ast .AsyncFunctionDef ]
163
+ ) -> Iterator [Tuple [str , ast .AST ]]:
162
164
def dotted (* nodes ):
163
165
return "." .join (_get_node_name (node ) for node in reversed (nodes ))
164
166
You can’t perform that action at this time.
0 commit comments