Skip to content

plugin

MkDocs plugin to integrate RobotFramework test reports.

RobotConfig

Bases: Config

Data class for mkdocs plugin config.

RobotPlugin

Bases: BasePlugin[RobotConfig]

mkdocs plugin to integrate RobotFramework test execution results.

on_files

on_files(files: Files, *, config: MkDocsConfig) -> Files

Handle the on_files event hook.

Source code in src/robot_markdown/plugin.py
41
42
43
44
45
46
47
48
49
50
51
52
53
54
def on_files(self, files: Files, *, config: MkDocsConfig) -> Files:
    """Handle the on_files event hook."""
    self._cachedirs = []

    renderer = Renderer()
    for report_config in self.config.reports:
        if report_config.cache_dir:
            self._process(renderer, report_config, report_config.cache_dir, files, config)
        else:
            cachedir = tempfile.TemporaryDirectory(prefix="mkdocs_robot_")
            self._cachedirs.append(cachedir)
            self._process(renderer, report_config, cachedir.name, files, config)

    return files

on_post_build

on_post_build(config: MkDocsConfig) -> None

Handle the on_post_build event hook.

Source code in src/robot_markdown/plugin.py
56
57
58
59
60
@event_priority(-100)
def on_post_build(self, config: MkDocsConfig) -> None:  # noqa: ARG002 (inherited method)
    """Handle the on_post_build event hook."""
    for cachedir in self._cachedirs:
        cachedir.cleanup()