← GDG /

#246 gdtest_header_file

#246 gdtest_header_file OK CONFIG
Tests include_in_header with a file reference
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

K42
K42include_in_header: fileconfig

Source Files

๐Ÿ“ gdtest_header_file/
๐Ÿ“„ __init__.py
"""Package testing include_in_header with a file reference."""

__version__ = "0.1.0"
__all__ = ["divide", "negate"]


def divide(a: float, b: float) -> float:
    """
    Divide a by b.

    Parameters
    ----------
    a
        Numerator.
    b
        Denominator.

    Returns
    -------
    float
        Quotient.
    """
    return a / b


def negate(x: float) -> float:
    """
    Negate a number.

    Parameters
    ----------
    x
        The number to negate.

    Returns
    -------
    float
        Negated value.
    """
    return -x
๐Ÿ“„ custom-head.html
<meta name="gd-file-inject" content="from-external-file">
๐Ÿ“„ great-docs.yml
include_in_header:
  - file: "../custom-head.html"