S SmartDocs
系列: python old python 7 行 · 更新于 2026-02-03

text_utils.py

python_old/pytest-workshop/pytest-workshop-starter/src/text_utils.py

# Capstone target
# Spec: lowercase, trim, collapse spaces to '-', remove non-alnum/hyphen,
# collapse multiple '-' to one, strip leading/trailing '-',
# empty/whitespace-only -> "".
# TODO: Implement this to pass tests.
def slugify(text: str) -> str:
    raise NotImplementedError("Implement in capstone exercise")

相关文章