mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-22 03:15:44 +00:00
87 lines
1 KiB
Python
87 lines
1 KiB
Python
"""Test: no-blank-line-after-function special-cases around comment handling."""
|
|
|
|
# OK
|
|
def outer():
|
|
"""This is a docstring."""
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# OK
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# OK
|
|
def outer():
|
|
"""This is a docstring."""
|
|
# This is a comment.
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# OK
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
# This is a comment.
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# OK
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
# This is a comment.
|
|
# Followed by another comment.
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# D202
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# D202
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
|
|
# This is a comment.
|
|
def inner():
|
|
return
|
|
|
|
return inner
|
|
|
|
|
|
# D202
|
|
def outer():
|
|
"""This is a docstring."""
|
|
|
|
# This is a comment.
|
|
|
|
def inner():
|
|
return
|
|
|
|
return inner
|