445 words
2 minutes
Basic Markdown
testing blog

This is a sentence with a footnote1.

Overview#

This file is a comprehensive testbed for the custom Org → GFM Lua filter. It exercises:

  • Metadata capture via top level #+KEY: VALUE lines go to markdown yaml frontmatter
  • Internal Org links (converted from spurious-link spans to GFM links)
  • Accurate Heading slugs with special characters handling
  • Named tables and code blocks (#+NAME) → HTML anchor spans
  • Code-block attributes (:mdparams, :lang, :name, etc.) passed through as Markdown fence attributes
  • Org exports (#+BEGIN_EXPORT markdown, #+begin_export html) literally to the markdown.

Use this file as a regression test when changing the filter.

Basic Internal Links#

Here is a link back to the first section:

Back to Section One

A link without an explicit description (description should default to the target text):

With out title Section One

Section One#

A reciprocal link back to itself (useful for testing idempotence):

Back to Section One

Slug & Heading Tests#

We now test headings and links that stress slug generation.

My heading (v2)

Intro & Usage#

The following link target includes punctuation and mixed case:

So this C++ Memory Model

C++ Memory Model#

Heading to test plus signs and spaces. The link above should correctly point here.

My heading (v2)#

A heading with parentheses and version information.

Back link to Intro & Usage:

Intro & Usage

Tables and Named Anchors#

This link should resolve to the named table below:

My simple table down below

Tables with Numbering#

Named table (tests #+NAME<span id="..."> anchor, with complex name):

Header 1Header 2
Data 1Data 2

Named code block (also testing #+NAME anchors for CodeBlock):

print("Hello")

A reference link that should point to the table anchor above:

This takes me to code block

Testing Heading Tags and folds#

Heading with attach tag ATTACH#

This heading’s tag will not be visible.

A heading with tags Demo Markup ATTACH Fold#

this heading has tags, one hidden one and it is foldable.

A foldable heading Fold#

this heading is foldable and initialy expanded state

Folded heading folded#

this is also foldable but initialy collapsed

Section Two folded#

this is also foldable but initialy collapsed

Exported Markdown & HTML Snippets#

The following block is exported as raw Markdown inside Org. It should pass through untouched and be rendered as-is in Markdown output.

Example Blocks#

An example block showing a text table from a tool

Output:
+-------------+---------------------------+ | schema_name | function_name | +-------------+---------------------------+ | pg_catalog | shobj_description | | pg_catalog | pg_typeof | | pg_catalog | pg_type_is_visible | | pg_catalog | pg_ts_template_is_visible | | pg_catalog | pg_ts_parser_is_visible | +-------------+---------------------------+

Raw HTML export (should be passed through untouched):

The ‘toml’ package isn’t installed. To load settings from pyproject.toml or ~/.jupysql/config, install with: pip install toml

Footnotes#

  1. This is the footnote content.

Basic Markdown
https://aneeqasif.github.io/posts/testing/basicmd/
Author
Aneeq Asif Azad
Published at
2026-09-09
License
CC BY-NC-SA 4.0