Guide

Testing Eleventy documentation examples

Eleventy can assemble a code block from data and includes before readers see it. Test the rendered code, not the template source.

Published
Updated
November 17, 2026
Reading time
13 min
Facts checked against
Eleventy docs on Markdown, Liquid, configuration, ignores, global data and passthrough copy, with every code block run on Eleventy 3.1.8, liquidjs 10.30.1, Node and Python 3 (November 14, 2026)
Outlined documentation pages with a lime pulse line running out of the stack
On this pageThe short answerHow Eleventy changes the testing boundaryWhy Eleventy examples break or get tested wronglyBuild a small probeCompare source scanning with the published pageRender a scan-ready copyTriage findings in contextRun both checks in CIMake the check repeatableWhere DocsAlive fitsThe sources we checkedFAQ

The short answer

Test Eleventy examples against what the published page actually shows. Eleventy can assemble a code block from data and includes before a reader sees it, while DocsAlive 0.6.3 does not detect Eleventy or render Liquid: it scans eligible source files as plain Markdown. In the verified probe, that difference produced a likely docs bug for an include-only block even though the published page was correct, scanned an ignored draft, and reported an unknown Liquid fence as passing without checking it. A render-for-scan copy narrows those gaps, but its limits need review.

A successful site build and a successful example run answer different questions. The build checks whether Eleventy can turn the project into pages. An example check asks whether the code a reader sees works in the environment and order the documentation describes. Both checks matter when source text is transformed before publication.

This guide uses a small Eleventy 3.1.8 project and the observed behavior of engine 0.6.3. The files are illustrative; the deliberately broken change is identified below. The commands show the verified workflow, but a real project should adapt the paths and rendering assumptions to its own configuration.

How Eleventy changes the testing boundary

Eleventy preprocesses Markdown as Liquid by default. The markdownTemplateEngine setting can select another engine, such as Nunjucks, or disable that preprocessing. A reader can therefore see code assembled from a data value and an included file even though neither appears as ordinary executable code in the source fence.

The default includes folder is _includes inside the input folder, and global data files belong in _data. Liquid include paths are quoted in the normal configuration; since Eleventy 1.0, unquoted paths require dynamicPartials to be false. Raw tags serve a different purpose: they preserve template syntax as literal content for a reader instead of letting the template processor interpret it.

Publication rules also affect the testing boundary. Eleventy supports .eleventyignore and programmatic ignore entries, automatically ignores paths in .gitignore, and always ignores node_modules. A source scanner that does not read those rules can report on a draft that the site never publishes. Conversely, a test that only runs an include file may miss the context in which the page presents it.

Eleventy item What Eleventy does What the engine does in 0.6.3
Markdown template engine Preprocesses Markdown as Liquid by default; configuration can change or disable it Does not detect Eleventy or render the selected template engine
Global data and includes Makes global data available and can insert included content into a page Reads source text; it does not assemble the reader-visible block
Raw tags and a Liquid fence Can preserve a literal template example Does not render the tags; the unknown Liquid fence reports pass without a check
Ignored draft Excludes it when the configured ignore applies Does not read Eleventy ignores and can scan the draft
Static file copy Can copy static files through passthrough configuration The probe did not use passthrough copy; do not infer coverage for it
Page selection Builds according to the Eleventy project configuration Uses plain-project collection rules and eligible Markdown suffixes

The engine scans .md, .mdx, and .markdown pages. It does not treat an included .py file or a template file as a page. For a plain project with a top-level docs/ folder, its default collection covers that folder and adds a root README when present. An include filter can narrow collected pages; it cannot recover pages from folders that collection always skips.

Why Eleventy examples break or get tested wrongly

Most broken examples on Eleventy sites are not caused by Eleventy. They come from the same drift every documentation site has: a package renames a function, a command gains a required flag, or a version string moves forward while the code around it stays the same. Eleventy adds a second layer on top of that drift, because the code a reader copies can be assembled at build time from pieces that live in different files.

The first piece is global data. A version number, package name or base URL often lives in a file under _data so every page stays consistent. That is good practice, but it means the code block in the source file is not the code the reader receives. Change the data file and every example that interpolates it changes too, without any edit to the pages themselves. A review of the page diff shows nothing; only a check of the rendered code shows the effect.

The second piece is includes. Teams keep longer samples as real source files under _includes so they can be linted or run on their own, then pull them into a fenced block with an include tag. Testing the included file directly is useful, but it does not prove the page presents it correctly. The include can point at the wrong file, a renamed file can leave the page empty, or the surrounding prose can promise setup the file does not perform.

The third piece is publication status. Drafts, archived pages and work in progress often sit in the same input folder and are kept out of the site with ignore rules. A source scanner that does not read those rules reports on pages no reader can open, which adds noise to a report and can bury the findings that matter.

The fourth piece is template syntax shown on purpose. A page that teaches Liquid or Nunjucks needs raw tags so the example survives the build. If the raw tags are missing, Eleventy either renders the example away or fails the build, depending on whether the expression is valid. Finally, a project can switch the Markdown template engine to Nunjucks or turn preprocessing off, which changes what every one of these pieces means. Know which engine the project uses before you decide how to prepare a scan.

Build a small probe

Start by creating the illustrative project and installing Eleventy. The tested setup also configured the package as a module and added a build script.

npm init -y
npm install --save-dev @11ty/eleventy

The illustrative configuration below sets the input and output folders, explicitly selects the default Markdown template engine, and excludes the draft path. The ignore entry matters later because the source scanner does not consume it.

export default function (eleventyConfig) {
  eleventyConfig.ignores.add("docs/drafts/**");
  return {
    dir: { input: "docs", includes: "_includes", data: "_data", output: "_site" },
    markdownTemplateEngine: "liquid",
  };
}

The illustrative global data file supplies the package name and version. The page will use the version inside a Python string, so the value that reaches the reader is significant to execution.

{
  "version": "2.4.1",
  "package": "acme-client"
}

The illustrative include is a complete Python source file. Eleventy inserts it into a fenced block on the page; the file itself is not a scanned Markdown page.

def connect(host, port=8080):
    return f"{host}:{port}"

print(connect("localhost"))

This illustrative page combines front matter, global data, an include, and a literal Liquid example. Read the two Python fences as reader-facing examples after Eleventy has processed the page. The last fence demonstrates template syntax and is intentionally preserved as text.

---
title: Install
layout: false
---
# Install {{ site.package }}

Check the version you are about to install:

```python
version = tuple(int(part) for part in "{{ site.version }}".split("."))
assert version >= (2, 0, 0)
print(version)
```

Connect to a local server:

```python
{% include "snippets/connect.py" %}
```

A Liquid example shown to readers, kept literal with raw:

{% raw %}
```liquid
{{ page.title }}
```
{% endraw %}

The next illustrative file is deliberately unsuitable for the current Python runtime. It is a draft, however, and the configured site build excludes it. Its presence in the repository alone does not mean a reader receives it.

# Next release (draft)

```python
from collections import Mapping
```

Build the project to see what Eleventy publishes. A successful build establishes that the template processing completed; it does not by itself execute the Python shown on the resulting page.

npx @11ty/eleventy

The following is the recorded build output for this probe. The built page contained the concrete version in the first Python block, the full included source in the second, and the literal template example. No page was written for the ignored draft.

[11ty] Writing ./_site/install/index.html from ./docs/install.md (liquid)
[11ty] Wrote 1 file in 0.13 seconds (v3.1.8)

Compare source scanning with the published page

The following command plans a scan of the source. Without execution, a scan extracts and plans blocks; the findings discussed here are what occurred when the probe was run.

docsalive scan .

The source scan collected three pages and five blocks: the root README, the install page, and the ignored draft. The version block failed with a runtime error needing review because the unrendered template text reached Python. The include-only block failed as invalid syntax and was counted as a likely docs bug, even though the published page contained valid included Python. That is a false docs bug caused by the rendering gap.

The draft produced an API-drift finding although Eleventy excluded it. The Liquid-labeled fence passed without being run or parsed: unknown fence labels have no checker in 0.6.3, so a pass is a known coverage limitation. The README package-install block was skipped with network disabled. None of these results says that the scanner saw the same page a reader saw.

Only printed output in pycon sessions is compared. Separate output blocks are skipped; a green result for a different block should not be read as a comparison of displayed results. See documentation drift for the broader problem of examples changing independently of the page around them.

Render a scan-ready copy

The following illustrative script was verified for this probe. It renders page bodies with the Liquid library installed with Eleventy, reads the one global data file, resolves includes, skips three named directories, and writes a Markdown copy. Keep that copy out of the repository or regenerate it in CI so stale generated pages do not become the thing being tested.

// Render Liquid in docs/*.md the way the site shows it, then write plain Markdown to scan.
import { Liquid } from "liquidjs";
import fs from "node:fs";
import path from "node:path";

const [src = "docs", out = "scan-docs"] = process.argv.slice(2);
const skip = ["_includes", "_data", "drafts"];
const site = JSON.parse(fs.readFileSync(path.join(src, "_data", "site.json"), "utf8"));
const liquid = new Liquid({ root: [path.join(src, "_includes")], extname: "" });

let count = 0;
for (const rel of fs.readdirSync(src, { recursive: true })) {
  if (!rel.endsWith(".md") || skip.some((dir) => rel.split(path.sep).includes(dir))) continue;
  const text = fs.readFileSync(path.join(src, rel), "utf8");
  const match = text.match(/^---\n[\s\S]*?\n---\n/);
  const head = match ? match[0] : "";
  const body = await liquid.parseAndRender(text.slice(head.length), { site });
  fs.mkdirSync(path.dirname(path.join(out, rel)), { recursive: true });
  fs.writeFileSync(path.join(out, rel), head + body);
  count += 1;
}
console.log(`rendered ${count} page(s) into ${out}/`);

Generate the copy before planning or running its scan. In the verified run, the scanner collected the copied install page and the root README, for two pages total. Both Python blocks passed when run; the Liquid fence still passed without a check.

node scripts/render-for-scan.mjs docs scan-docs
docsalive scan . --docs-dir scan-docs

The script reported one copied page. The additional page in the scan was the root README automatically added for the plain project.

rendered 1 page(s) into scan-docs/

This deliberately broken data change illustrates why rendering matters. Eleventy still built successfully, but the rendered version block failed when run because the version contained a nonnumeric component. That is a failure a reader copying the rendered code would encounter.

-  "version": "2.4.1",
+  "version": "2.x",

The script is a targeted adapter, not an Eleventy build. It loads only site.json, not every global data file, front matter variable, or computed value. It does not know custom filters or shortcodes from the Eleventy configuration. It uses Liquid library defaults rather than Eleventy’s exact Liquid options, handles Liquid only, and will not reproduce a Nunjucks configuration. Its skip list is hard-coded rather than read from Eleventy ignores. Compare representative copied pages with built pages whenever those assumptions change.

Triage findings in context

Finding Likely cause What to do
Version code fails on template text Source was scanned before data was rendered Compare the built page and a rendered copy; run the concrete value
Include-only block is marked invalid syntax The include tag was treated as Python Verify the included file and scan a faithful rendered page
Draft produces API drift The scanner did not read the site ignore rules Decide whether the draft belongs in the release check and align the copy’s skip list
Liquid fence passes Its label has no checker in 0.6.3 Review the example separately; do not interpret the pass as validation
README install step is skipped Network was disabled Record the gap and use an appropriate network-enabled check when needed
A rendered example fails The value or included code may be genuinely broken Reproduce with the documented setup and decide whether the page needs a change

Use finding categories to distinguish likely docs bugs from results that need review. A clean scan is meaningful only alongside the page list, skipped reasons, setup, and the transformation used to create the input.

Run both checks in CI

Treat the Eleventy build and the example check as two separate steps with separate meanings. The build step answers whether the site can be produced at all: missing includes, invalid template syntax and configuration errors stop it. The example step answers whether the code readers see actually works with the prerequisites the page states. One does not replace the other, and a pipeline that only builds the site will stay green while examples drift.

A practical order is to install dependencies, build the site, regenerate the scan-ready copy from the same checkout, and then scan the copy. Regenerating the copy in the same job matters: a copy committed weeks ago tests old data and old includes, which is exactly the drift you are trying to catch. Add the copy folder to the ignore rules of your version control so nobody edits it by hand.

Decide in advance which results block a merge. A reasonable starting point is to block on likely docs bugs found in the rendered copy and to report, but not block on, results that need review. Record the skipped blocks and the unknown fence labels in the job summary so reviewers can see what was not checked. When the scan of the raw source and the scan of the copy disagree, trust the copy only after comparing a few rendered pages with the built HTML; that comparison is what keeps the adapter honest. The GitHub Actions guide shows how to wire a scan into a workflow.

Make the check repeatable

Use this checklist in a review or CI plan. It records both the published-page boundary and the remaining gaps.

[ ] Build the Eleventy site with its intended configuration.
[ ] Identify the Markdown template engine and reader-visible data and includes.
[ ] Compare representative built pages with the scan-ready copy.
[ ] Match the copy's exclusions to the pages intended for publication.
[ ] Regenerate the copy before scanning and keep stale copies out of the repository.
[ ] Review the collected pages, skipped blocks, and unknown fence labels.
[ ] Reproduce likely docs bugs with the documented setup and concrete values.
[ ] Check template examples and unsupported behavior separately.

Where DocsAlive fits

DocsAlive fits after the page boundary is understood. It extracts fences, plans supported checks, runs examples in isolated per-page containers, and classifies findings so maintainers can focus on likely documentation defects. Its CLI reference describes scan controls, while the framework reference describes supported detection. Use Eleventy’s own build alongside it, and use a separately verified adapter when source and published examples differ.

On an Eleventy site, the realistic setup in 0.6.3 is the build for template errors, the rendered copy for the code readers see, and the scan with triage on top of that copy. Every plan runs the scan on a schedule, and the Team plan and above add pull request checks and draft fix pull requests; see pricing for what each plan includes. To see a real report on a public repository you maintain, send it through the health check.

For a broader workflow, see static-site documentation testing and the documentation testing checklist. Projects mixing generators may also need the distinct boundaries in Zola and Quarto.

The sources we checked

These sources were read on November 14, 2026. Engine behavior was checked against engine 0.6.3 on the same day.

Source What it covers
Eleventy Markdown Markdown preprocessing
Eleventy Liquid Liquid and include behavior
Eleventy configuration Project configuration
Eleventy ignores Ignored paths
Eleventy global data Global data files
Eleventy passthrough copy Static file copying
Python 3.10 changes Removed compatibility aliases

FAQ

Does DocsAlive understand Eleventy in 0.6.3?

No. It does not detect Eleventy and scans eligible files as plain Markdown without rendering Liquid. In the probe it counted an include-only block as a likely docs bug although the published page was correct, scanned an ignored draft, and reported an unknown Liquid fence as passing without a check.

Is a successful Eleventy build an example test?

No. It confirms that the site built, but the displayed code can still fail when a reader runs it. Test the concrete code the built page presents as well as the build.

Why did an ignored draft appear in the scan?

Engine 0.6.3 does not read Eleventy ignore rules. A draft can remain an eligible Markdown file in the repository even though Eleventy excludes it from publication.

Does the render-for-scan script reproduce every Eleventy project?

No. It handles the probe’s Liquid, one data file and a hard-coded skip list. It does not reproduce all data, custom template behavior, Eleventy Liquid options or another configured template engine.

What does a passing Liquid fence mean?

In engine 0.6.3 that unknown label is reported as passing without being run or parsed. Review the example with a suitable separate check.

What should maintainers do with a likely docs bug?

Reproduce it using the reader-visible code and documented setup. Check whether rendering, an ignored page, missing context or a real code change explains the result before editing the documentation.

Keep reading
Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs Testing: How to Test the Code Samples in Your Docs

Why code examples in documentation break, the ways teams test them (doctest, docs-as-tests, CI runners) and how to run every sample on each release.

Two lenses held over the same documentation page, each bringing a different layer into focusComparison

Vale vs markdownlint: What Each Docs Linter Catches

Vale checks prose style; markdownlint checks Markdown structure. What each catches, sample configs, running both in CI and what neither one tests.

Blueprint of two documentation pages: one with a handwritten test script, one whose code blocks are framed and checkedComparison

Doc Detective vs DocsAlive: Testing the Code in Your Docs

Doc Detective is a free, open-source docs-as-tests framework; DocsAlive is a hosted docs CI for code examples. Features, price, setup and when to use each.

A machine blueprint above a ruled documentation page, with a caliper measuring between themComparison

Promptless Alternative: Promptless vs DocsAlive Compared

Promptless drafts docs updates from what you ship; DocsAlive runs the code examples you've published. Features, pricing, security and when to use each.

A long workbench of outlined testing instruments, each with a small lime light, beside a stack of documentation pagesGuide

Best Free Tools to Test Code Examples in Documentation

Free, open-source tools that run the code examples in your docs: rustdoc, Go examples, doctest, pytest plugins, Sphinx doctest, Doc Detective and byexample.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing SDK Docs Before Every Release: A Release-Gate Guide

Test SDK and client-library docs against the package you ship: build the wheel or npm tarball, install it clean, run every example, and gate the release in CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

How to Test Quickstarts and Tutorials in Your Docs

Test the onboarding path a new reader follows: run quickstarts in a clean environment, in page order, sort real bugs from credentials and fragments, and wire it into CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

How to Test CLI Documentation: Commands, Flags and Output

Test the commands a CLI page promises: install in a clean container, run examples in order, compare flags with --help, check exit codes and output, and run it in CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

How to Test API Reference Docs: Requests, Responses and SDKs

Test API reference pages against the contract they publish: methods, parameters, request and response examples, SDK snippets, status codes and OpenAPI samples.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs testing for API-first companies

Keep API quickstarts, SDK snippets and curl examples working across releases.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs testing for CLI and developer-tool vendors

Test developer-tool install paths, package managers and command examples across releases.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing README Code Examples: Install, Usage and CI

Keep README install commands and usage examples working with clean environments, output checks and CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Notebooks and Executable Docs: Cells, Kernels and Output

Test notebooks in fresh kernels, check meaningful output and manage dependencies, data and drift in CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Docs in GitHub Actions: Pull Requests and Scheduled Checks

Run documentation example checks in GitHub Actions with practical guidance on schedules, path filters, caching, secrets and reports.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Code Examples in MkDocs, Docusaurus and Sphinx Sites

Find and test documentation examples in Markdown, MDX and reStructuredText, alongside site builds and link checks.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Python Docs Testing: Doctest, Pytest and Markdown

Test Python documentation with doctest, pytest, Markdown example execution and isolated environments.

Outlined documentation pages with a lime pulse line running out of the stackGuide

JavaScript Docs Testing: Node, TypeScript and Modules

Test Node and TypeScript documentation examples across module formats, package versions and type checks.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Go documentation examples

Test Go example functions and Markdown snippets against the intended module versions in clean environments.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Sphinx Docs Testing: doctest, code-block and MyST

Test Sphinx documentation examples: what the doctest and linkcheck builders prove, code-block and literalinclude, MyST fences, and what a Markdown scan covers.

Outlined documentation pages with a lime pulse line running out of the stackGuide

ReadMe Docs Testing: CLI, OpenAPI and Code Examples

Test ReadMe documentation examples: docs-as-code and bi-directional sync, what lint and oas:validate prove, Tabs variants and runnable code.

Outlined documentation pages with a lime pulse line running out of the stackGuide

TypeScript Docs Testing: tsc --noEmit and Runtime

Test TypeScript documentation examples: type-check snippets with tsc --noEmit in a consumer project, then run them, and what each check proves.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docusaurus Docs Testing: Code Blocks, Tabs and MDX

Test Docusaurus documentation examples: builds vs runnable code, code block metadata, Tabs install variants, MDX pages and clean-container runs.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Mintlify Docs Testing: CodeGroup, Tabs and the CLI

Test Mintlify documentation examples: docs.json, MDX pages, CodeGroup and Tabs variants, what mint broken-links and mint validate prove, and clean runs.

Outlined documentation pages with a lime pulse line running out of the stackGuide

MkDocs Docs Testing: Code Examples, Tabs and Snippets

Test MkDocs documentation examples: strict builds, Material tabs, Snippets includes, mkdocstrings pages and clean-container runs.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Installation Instructions: pip, npm and Containers

Test documented install steps in clean environments: pip and extras, venv, npm install vs npm ci, containers and the first import.

Outlined documentation pages with a lime pulse line running out of the stackGuide

AI SDK Docs Testing: LLM Examples, Keys and Drift

Test AI and LLM SDK documentation examples: requests, responses, streaming, tool calls, credentials, model retirements and CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing migration guides and changelog examples

Test before and after examples against the right releases and make migration documentation part of the release gate.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs Testing Checklist: Code Examples Before Release

A practical pre-release checklist for testing documentation examples, reviewing gaps and verifying published packages.

Outlined documentation pages with a lime pulse line running out of the stackGuide

The Cost of Broken Code Examples in Documentation

Understand how broken documentation examples create friction in developer adoption and support, and how to reduce it.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Rust documentation examples

Test Rust rustdoc examples and cargo documentation tests, and keep native Rust checks because compiled Rust fences are recognized but not executed.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing VitePress documentation examples

Test VitePress Markdown examples separately from the site build, including code groups, includes and what a plain Markdown scan covers.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing docs in GitLab CI

Run documentation example checks in GitLab CI jobs, keep site builds separate from execution, and review what a scan covers and skips.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing JSON, TOML and YAML examples in docs

Test JSON, TOML and YAML config examples in documentation: parse, schema and tool checks, honest fence labels, fragments, CI jobs and what a scan covers.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Java documentation examples

Test Java examples in READMEs, SDK docs and Javadoc: the source launcher, javac, JShell scripts, assertions, @snippet files, CI and what a scan covers.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing PHP documentation examples

Test PHP examples in docs: php -l lint, clean-directory runs, assertions with zend.assertions, Composer scratch projects, PHPUnit, CI and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing C# documentation examples

Test C# examples in docs: .NET 10 file-based apps, dotnet build with warnings as errors, test projects, XML doc comments, CI and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Ruby documentation examples

Test Ruby examples in docs: ruby -c syntax checks, clean-directory runs, bundler/inline, minitest assertions, YARD examples, CI and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Kotlin documentation examples

Test Kotlin examples in docs: kotlinc runnable JARs and scripts, -Werror, KDoc @sample in compiled source, kotlinx-knit, fence labels, CI and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Swift documentation examples

Test Swift examples in docs: swift scripts, swiftc -typecheck, DocC snippets compiled by swift build, Swift Testing assertions, CI containers and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing curl and HTTP examples in API docs

Test curl examples in API docs: --fail-with-body, status and JSON checks against a local stub, http fences, credentials and what a docs scan checks.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Astro Starlight documentation examples

Test code examples in Astro Starlight docs: src/content/docs inventory, Tabs and Expressive Code, Markdoc pages, a Node check script, CI and scan coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Nextra documentation examples

Test code examples in Nextra docs: content/ and app/ sources, fence metadata, Tabs and npm2yarn, a Node check script, CI and an honest scan limitation.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs testing for open-source projects

Test the code examples in open-source docs and READMEs: pull requests from forks, release and scheduled checks, contributor guidelines, triage and the Open source plan.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs testing for technical writers and docs teams

How technical writers and docs teams test the code examples they publish: docs-as-code checks, style-guide rules, reading a report, routing findings to engineers.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Docs testing for DevRel teams

How developer advocates test quickstarts, tutorials, workshops and sample READMEs: an inventory, a launch and release cadence, reading a report, and honest reporting.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Hugo documentation examples

Test the code examples in Hugo docs: fences with brace options, the highlight shortcode, Docsy tabs, drafts and theme example sites, scan scope and CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing GitBook documentation examples

Test the code examples in GitBook docs synced to Git: the space root, code tags, tabs, reusable includes, invisible characters, scan scope and CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing SQL examples in documentation

Test SQL examples in docs: run fences in page order on a fresh database, assert results, handle dialects, SQLite STRICT typing, psql ON_ERROR_STOP and CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing mdBook documentation examples

Test the code in an mdBook: what mdbook test covers, rust attributes, hidden lines, include directives, untagged output fences and a scan-ready copy for CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Docsify documentation examples

Test the code examples in Docsify docs: embedded code files and fragments, docsify-tabs tab sets, Prism grammars, scan scope and a CI check.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Jekyll documentation examples

Test the code examples in Jekyll docs: include tags, site variables, highlight tags, posts and _site copies, a scan-ready copy and Ruby hooks.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Antora and AsciiDoc documentation examples

Test the code examples in Antora docs: example includes, tagged regions, attributes, failing the build on missing includes and a Markdown copy to scan.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Fumadocs documentation examples

Test the code examples in Fumadocs docs: npm fences and package-manager tabs, tab groups, the Tabs component, includes, pycon highlighting and a scan-ready copy.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing versioned Docusaurus docs

Test every Docusaurus version readers can reach: versioned_docs copies, versions.json, partials, tabs, per-version scans and old-version triage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Read the Docs documentation examples

Test the code examples on a Read the Docs site: .readthedocs.yaml build jobs, a pycon gate, latest and stable versions, Sphinx, MyST and .rst coverage.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Zola documentation examples

Test the code examples in Zola docs: Tera content templating, raw tags, config values, hide_lines, drafts, blog posts and a scan-ready copy.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Quarto documentation examples

Test the code examples in Quarto docs: executable cells, display-only fences, freeze and _freeze, a CI profile, cell options and a copy to scan.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Hexo documentation examples

Test the code examples in Hexo docs: posts, drafts, scaffolds, codeblock and include_code tags, a build check and a scan-ready copy.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing pdoc documentation examples

Test the code examples in pdoc docs: doctest for >>> sessions, fenced docstring examples, the README, private items and a copy to scan.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Doxygen documentation examples

Test the code examples in Doxygen docs: compiled example files, snippets, Markdown pages, WARN_AS_ERROR and what a scan can and cannot check.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing TypeDoc documentation examples

Test the code examples in TypeDoc docs: example tags, includeCode regions, project documents, a compiler check of extracted examples and a scan.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing JSDoc documentation examples

Test the code examples in JSDoc docs: example tags, captions, source patterns, tutorials, a doclet export and a scan-ready copy with assertions.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing docs examples with pre-commit hooks

Check docs code examples with pre-commit: local hooks, files filters, always_run, pass_filenames, SKIP and --no-verify, and what to leave for CI.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing documentation examples with Deno

Run docs code examples with deno test --doc: JSDoc and Markdown examples, imports, hashbang permissions, ignored blocks and deno check --doc-only.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing documentation examples with Sybil

Test Python docs examples with Sybil and pytest: Markdown parsers, invisible setup, skips, clear-namespace, docstrings and pycon fences a scan can read.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Markdoc documentation examples

Test the code examples in Markdoc docs: variables in fences, partials, if/else, custom tabs, validate in CI and a scan-ready copy from transform.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Markdown examples with phmdoctest

Test Python examples in README and Markdown files with phmdoctest: sessions, output blocks, directives, --report, generated pytest files and pycon fences.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Markdown code blocks with pytest-markdown-docs

Run Markdown python fences as pytest tests with pytest-markdown-docs: globals hook, fixtures, continuation, notest, retry and pinning the released version.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing command line docs with prysk and Cram

Test CLI docs with prysk and Cram: .t transcripts, exit statuses, (re) and (glob) matches, and generating tests from the console blocks in your Markdown.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Python docstring examples with xdoctest

Run docstring examples with xdoctest: the pytest plugin, google and freeform parsing, permissive output matching, directives, and what it does not check.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing multi-language docs examples with byexample

Test docs examples with byexample: prompt-based language detection, the -l selection, +pass, +skip and timeouts, capture tags, and hidden setup in comments.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Markdown code blocks with mktestdocs

Run Markdown code blocks under pytest with mktestdocs: exact fence labels, memory=True for shared state, bash blocks, custom executors and docstring checks.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing README code blocks with pytest-codeblocks

Run README and Markdown code blocks with pytest-codeblocks: exact python, sh and bash labels, cont, skip and xfail markers, expected output, and gaps.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Markdown code examples in any language with txm

Test annotated Markdown examples with txm: program, in, out, err, check and exit annotations, TAP output, exact matching, and blocks it never runs.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing Sphinx docs examples with sphinx.ext.doctest

Run Sphinx doctest, testcode and testoutput directives in reStructuredText or MyST pages: groups, hidden setup, global setup and what is never run.

Outlined documentation pages with a lime pulse line running out of the stackGuide

Testing docs examples that need API keys

Test credential-gated docs examples: honest placeholders, offline stubs and fixtures, live sandbox jobs, CI secrets and fork rules, and how a scan classifies them.

A machine blueprint above a ruled documentation page, with a caliper measuring between themGuide

Documentation Drift: How to Detect It Before Users Do

What documentation drift is, why code examples drift first, and practical ways to detect it: ownership, release checks, link and execution tests.

See which of your code samples still run.

Send us a public repository. Our team runs DocsAlive on its docs and emails you the real report within 2 business days. Free, no signup.