Skip to main content

A CLI Tool to generate a Test Documentation for your RobotFramework Test Scripts.

Project description

robotframework-testdoc

The new tool to generate test documentation pages for your Robot Framework project.

GitHub Project

Visit the project at GitHub - robotframework-testdoc

Documentation

Visit the official documentation for more details: Documentation - robotframework-testdoc

VS Code Extension

Generate test documentation directly from the VS Code Explorer — no terminal required.
Download the latest .vsix from GitHub Releases and install it locally.

code --install-extension testdoc-vscode-<version>.vsix

See the VS Code Extension documentation for details.

Statistics

Release Pipeline
PyPI - Version
PyPI - Python Version
PyPI Downloads - Total
PyPI Downloads - Monthly

Installation

Install the tool using the following command:

pip install robotframework-testdoc

Usage

Basic Usage

testdoc suite_directory output.html
# or
testdoc suite_file output.html

General Usage

Extended Usage

testdoc [OPTIONS] suite_directory output.html

[!TIP] Included Help: Visit the CLI Documentation for further arguments & details.

Output Formats

By default testdoc generates an HTML file. Use -f / --output-format to choose a different format:

# HTML (default)
testdoc tests/ TestDocumentation.html

# JSON — machine-readable suite tree
testdoc -f json tests/ TestDocumentation.json

Available values: html (default), json.

Plugin Usage

You can use the testdoc tool also as plugin integration.
You have two option to use it this way:

  1. You can write your own HTML page as jinja2 template, add this HTML template as CLI argument while generating the docs and you will get your own HTML style as documentation page.
  2. You can use the mkdocs integration to define your own mkdcs template as CLI argument and the testdoc tool will internally take care of the mkdocs page generation.

For further details about the usage, please read the official documentation.

Use customized Jinja2 HTML Template

Custom Jinja Template

Use internal Mkdocs Template

Internal Mkdocs Template

Use customized Mkdocs Template

Custom Mkdocs Template

Examples

Visit the official documentation to find some Examples.

External Configuration File

The idea of the external configuration file is, having a central place for passing the known CMD arguments via file instead of CMD parameters.
This will keep your CMD line call simple & clean.

For using this config file, just call the following command:

# Generate docu with options defined in TOML file
testdoc -c path/to/config.toml tests/ TestDocumentation.html

pyproject.toml vs. custom toml file

Using the pyproject requires to define the testdoc sections with the prefix tool.
Example section start: [tool.testdoc]

Using your own custom toml-file, does not require you to use the prefix. Here, you can just use [testdoc] as section header.

Example Configuration File

[tool.testdoc]
title = "New title of HTML document"
name = "New name of root suite element"
doc = "New doc text of root suite element"
sourceprefix = "gitlab::https://gitlab.com/myrepo/repo_path"
include = ["TagA", "TagB"]
exclude = ["TagC"]
verbose_mode = false

[tool.testdoc.metadata]
Author = "Your-Name"
Version = "1.0.0"
Source = "AnySourceAsMetaData"

Contribution & Development

See Development.md for more information about contributing & developing this library.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

robotframework_testdoc-0.6.3a3.tar.gz (14.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

robotframework_testdoc-0.6.3a3-py3-none-any.whl (65.2 kB view details)

Uploaded Python 3

File details

Details for the file robotframework_testdoc-0.6.3a3.tar.gz.

File metadata

  • Download URL: robotframework_testdoc-0.6.3a3.tar.gz
  • Upload date:
  • Size: 14.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for robotframework_testdoc-0.6.3a3.tar.gz
Algorithm Hash digest
SHA256 e808daef43a0e25b572b243ba73ac7aa64aec64bcf0f597a32e488c6c38ea145
MD5 14f871340f50f59cbb7d98eecdcb9989
BLAKE2b-256 8aef21d4a2f9f51a82ab86b5d40be694a273f253c9e29163bf44de59e1842bee

See more details on using hashes here.

File details

Details for the file robotframework_testdoc-0.6.3a3-py3-none-any.whl.

File metadata

File hashes

Hashes for robotframework_testdoc-0.6.3a3-py3-none-any.whl
Algorithm Hash digest
SHA256 1afacf8c99f48b6e90985738c10abda0c478e085fe3fd28befd60edba094649b
MD5 032f42991aa6c402b4793aaa01a74ef2
BLAKE2b-256 9a911cb894e549ef5ca6a85920225e47c42c09b6c1db3a5f4b8b8acab4235324

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page