← GDG /

#125 gdtest_rst_versionadded

#125 gdtest_rst_versionadded OK CONFIG
Tests versionadded RST directives in docstrings
Docstrings contain '.. versionadded:: 2.0' RST directives. The built-in handler should convert them into Quarto note callouts with version info. Two functions with versionadded in their docstrings.
View Site → Build Log ๐Ÿงช Test Coverage

Build Mode

● Has great-docs.yml

This package ships a pre-supplied config. The great-docs init step is skipped and great-docs build uses the spec-defined configuration directly. Tests specific config options and their rendered output.

Dimensions

L1
L1.. versionadded::docstring

Source Files

๐Ÿ“ gdtest_rst_versionadded/
๐Ÿ“„ __init__.py
"""Package testing versionadded RST directives."""

__version__ = "0.1.0"
__all__ = ["create_session", "close_session"]


def create_session(name: str) -> str:
    """
    Create a new session with the given name.

    Parameters
    ----------
    name
        The name for the new session.

    Returns
    -------
    str
        The session identifier.

    .. versionadded:: 2.0
    """
    return f"session-{name}"


def close_session(session_id: str) -> None:
    """
    Close an existing session.

    Parameters
    ----------
    session_id
        The identifier of the session to close.

    Returns
    -------
    None

    .. versionadded:: 2.1
        Session cleanup was added.
    """
    pass
๐Ÿ“„ README.md
# gdtest-rst-versionadded

Tests versionadded RST directives in docstrings.
๐Ÿ“„ great-docs.yml
parser: sphinx