The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable.

MITAuto-check passedTesting & QA

Install TDD

skills CLI
$ npx skills add RafaelGB/Obsidian-ZettelFlow --skill tdd -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install RafaelGB/Obsidian-ZettelFlow tdd --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/RafaelGB/Obsidian-ZettelFlow.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/tdd .claude/skills/tdd && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
tdd
GitHub stars
174
Token cost
~724 tokens
SKILL.md length
308 words
Files
1
Skills in repo
9
Repo updated
First seen
Licence
MIT

At a glance

The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable.

  • Works in 3 steps: Red — write a failing test in test/,… → Green — implement the minimal change to… → Refactor — clean up while keeping the…
  • Changing plugin logic
  • SKILL.md covers The loop (red → green →…, How tests are wired, What to test first (highest… and Harder (defer until needed), plus 2 more sections
  • Calls npm

What it does

TDD is an agent skill from RafaelGB/Obsidian-ZettelFlow. The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable. Use when adding or changing plugin logic, fixing a bug, or when the user asks to "write a test", "do TDD", "add coverage", or works on any of the Obsidian-score issues.

Its SKILL.md is about 720 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Testing & QA, covering Test-driven development and Unit testing. It works with Obsidian, Jest and npm. The repository describes itself as: ZettelFlow is a plugin for Obsidian that helps you to create and manage your notes in a Zettelkasten way. The licence is MIT.

When your agent uses it

  • Changing plugin logic
  • The user asks to write a test
  • Works on any of the Obsidian-score issues

Example prompts

  • “write a test”
  • “do TDD”
  • “add coverage”
  • “/tdd”

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Red — write a failing test in test/, mirroring the source path
  2. Green — implement the minimal change to make it pass.
  3. Refactor — clean up while keeping the suite green.

What it can do on your machine

Read from SKILL.md and the folder at commit 0676350. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npm

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use npm, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

TDD loads about 724 tokens when it runs. Until then it costs about 91 tokens; SKILL.md has 308 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~91
When it runs · the whole SKILL.md, loaded when a task matches
~724

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from RafaelGB/Obsidian-ZettelFlow at commit 0676350, republished under its MIT licence (© RafaelGB). 308 words, ~724 tokens.

Download SKILL.mdSave it as .claude/skills/tdd/SKILL.md (or your agent's skills folder).
name
tdd
description
The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable. Use when adding or changing plugin logic, fixing a bug, or when the user asks to "write a test", "do TDD", "add coverage", or works on any of the Obsidian-score issues.

TDD workflow for ZettelFlow

Development here is test-first. The blocking guardrails are typecheck + oxlint + jest (enforced by the pre-push husky hook and the CI workflow). The Obsidian guideline lint (lint:obsidian) is advisory. Full rationale: docs/development/testing-and-guardrails.md.

The loop (red → green → refactor)

  1. Red — write a failing test in test/, mirroring the source path (test/<area>/<Name>.test.ts). Import from @jest/globals (import { describe, it, expect } from "@jest/globals").
  2. Green — implement the minimal change to make it pass.
  3. Refactor — clean up while keeping the suite green.

Iterate with npm run test:watch; run npm test once; run npm run verify (typecheck + oxlint + test) before committing.

How tests are wired

  • Tests live under test/ (not src/), so the release tsc and esbuild never compile them.
  • Import source through the same bare aliases as the app (architecture/..., hooks/..., application/...); jest resolves them via moduleNameMapper in jest.config.js (mirrors tsconfig baseUrl: src).
  • The Obsidian runtime is stubbed by test/__mocks__/obsidian.ts. Extend that mock when the unit under test imports more of the Obsidian API (add the class/function you need).
  • ts-jest compiles with tsconfig.jest.json (transpile-only via isolatedModules).

What to test first (highest ROI, no Obsidian runtime)

  • Pure helpers: architecture/styles/helper.ts, hooks/utils/* (already seeded).
  • Note assembly: application/notes/ContentDTO & NoteDTO (zones, {{key}} substitution, tag de-dup) — may need a couple more mock stubs.
  • Flow graph traversal: architecture/plugin/canvas/Flows (FlowImpl.rootNodes/childrensOf).
  • Wizard transitions: the noteBuilder callbacks with fake flow/state.

Harder (defer until needed)

  • React components / modals → add jest-environment-jsdom + @testing-library/react and set testEnvironment: "jsdom" for those files.
  • The canvas monkey-patcher against a real Canvas → integration territory, not unit tests.

TDD for a bug fix (required for the score issues)

Reproduce the bug as a failing regression test first, then fix it. Every fix that closes an Obsidian-score issue should land with the test that proves it.

Commands

npm test · npm run test:watch · npm run test:coverage · npm run typecheck · npm run lint (oxlint) · npm run lint:obsidian (advisory) · npm run verify

© RafaelGB, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/tdd of RafaelGB/Obsidian-ZettelFlow.

Open the folder on GitHubat commit 0676350

Compare with similar skills

TDD next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

TDD compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
TDD this skillRafaelGB/Obsidian-ZettelFlow174—~724Automated safety check: PassMIT
Jest Testing PatternsChrisWiles/claude-code-showcase6.1k7 repos~1.5kAutomated safety check: PassNone
Test Guidelinesgetsentry/sentry-react-native1.8k—~1.3kAutomated safety check: PassMIT
Run Unit TestsAzure/cosmos-explorer131—~638Automated safety check: PassMIT
MoAI TDD Workflowmodu-ai/moai-adk1.2k—~3.1kAutomated safety check: PassApache-2.0
Tsed Migrationtsedio/tsed3.1k—~2.5kAutomated safety check: PassMIT

Similar skills

  • Jest Testing Patterns

    ChrisWiles/claude-code-showcase

    Jest patterns for React Native style tests: TDD discipline, mock factory functions, module and GraphQL hook mocking, custom render helpers and anti-patterns to avoid.

    6.1k GitHub starsUsed in 7 repos~1.5k tokens
    Testing & QAAuto-check passed
  • Test Guidelines

    getsentry/sentry-react-native

    Official

    Enforce Sentry React Native SDK test conventions for naming, structure, mocking, and fixtures with Jest.

    1.8k GitHub stars~1.3k tokensUpdated yesterday
    Testing & QAAuto-check passed
  • Run Unit Tests

    Azure/cosmos-explorer

    Official

    Run unit tests for the Cosmos Explorer project. An agent skill from Azure/cosmos-explorer.

    131 GitHub stars~638 tokensUpdated yesterday
    Testing & QAAuto-check passed
  • MoAI TDD Workflow

    modu-ai/moai-adk

    Drives test-first development through the RED, GREEN, REFACTOR cycle, with a config switch that selects between TDD and a DDD workflow for existing code.

    1.2k GitHub stars~3.1k tokensUpdated yesterday
    Testing & QAAuto-check passed
  • Tsed Migration

    tsedio/tsed

    Migrates an application to Ts.ED v8 from v7, with pointers for v6 and plain Express apps.

    3.1k GitHub stars~2.5k tokensUpdated yesterday
    Testing & QAAuto-check passed
  • Enforces strict red-green-refactor, with a failing test first, the minimum code to pass it, then cleanup, and a quick reference for common test runners.

    2k GitHub starsUsed in 1 repo~904 tokens
    Testing & QAAuto-check passed

More from RafaelGB/Obsidian-ZettelFlow

All 9 skills in this repo
  • New Action

    RafaelGB/Obsidian-ZettelFlow

    Scaffold a new ZettelFlow action following the project's 4-file convention (Action / Component / Settings / SettingsReader), register it, and document it.

    174 GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Obsidian Plugin Quality

    RafaelGB/Obsidian-ZettelFlow

    Audit ZettelFlow against the official Obsidian plugin guidelines and the Community-hub automated review / quality score.

    174 GitHub stars~1.6k tokensUpdated yesterday
    Auto-check passed
  • Release

    RafaelGB/Obsidian-ZettelFlow

    Cut a compliant ZettelFlow plugin release — version bump, versions.json, build, tag, and a GitHub Release whose notes follow the house format.

    174 GitHub stars~1.4k tokensUpdated yesterday
    Auto-check passed
  • Specify

    RafaelGB/Obsidian-ZettelFlow

    Stage 1 of the SDD pipeline — write a ZettelFlow spec into a GitHub issue body (problem, value, functional requirements, testable acceptance criteria, capability disclosure, out-of-scope).

    174 GitHub stars~759 tokensUpdated yesterday
    Auto-check passed
  • Sdd

    RafaelGB/Obsidian-ZettelFlow

    The Spec-Driven Development pipeline for ZettelFlow — the end-to-end flow (constitution → specify → plan → tasks → implement → verify) and which skill/agent owns each stage.

    174 GitHub stars~842 tokensUpdated yesterday
    Auto-check passed
  • Implement

    RafaelGB/Obsidian-ZettelFlow

    Stage 4 of the SDD pipeline — execute a ZettelFlow task checklist (in a GitHub issue comment) test-first (red → green → refactor), one commit per advance, keeping npm run verify green and CI green…

    174 GitHub stars~1.7k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about TDD

What does TDD do?

The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable. TDD is an agent skill from RafaelGB/Obsidian-ZettelFlow. The test-driven development workflow for ZettelFlow — write a failing test first, run jest, use the Obsidian mock and the bare-specifier alias mappings, and know which code is unit-testable.

When should I use TDD?

TDD fits situations like: changing plugin logic; the user asks to write a test; works on any of the Obsidian-score issues.

How do I install TDD in Claude Code?

Run `npx skills add RafaelGB/Obsidian-ZettelFlow --skill tdd -a claude-code`. Or copy the skill folder (.claude/skills/tdd in RafaelGB/Obsidian-ZettelFlow) into .claude/skills/tdd in your project. Claude Code loads it when a task matches its description.

How do I install TDD in Codex?

Run `npx skills add RafaelGB/Obsidian-ZettelFlow --skill tdd -a codex`. Or copy the skill folder (.claude/skills/tdd in RafaelGB/Obsidian-ZettelFlow) into .agents/skills/tdd in your project. Codex loads it when a task matches its description.

Can I use TDD in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add RafaelGB/Obsidian-ZettelFlow --skill tdd -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/tdd, .gemini/skills/tdd, .github/skills/tdd and .opencode/skills/tdd in your project.

What does TDD need to run?

Going by SKILL.md and its folder, TDD needs the command-line tools its instructions call (npm).

Does TDD access the network?

SKILL.md contains no URLs. Its commands use npm, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is TDD safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does TDD use?

TDD is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does TDD use?

About 724 tokens (SKILL.md is roughly 2.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to TDD?

Skills that share tags, products or a category with TDD: Jest Testing Patterns (ChrisWiles/claude-code-showcase, 6.1k stars), Test Guidelines (getsentry/sentry-react-native, 1.8k stars), Run Unit Tests (Azure/cosmos-explorer, 131 stars) and MoAI TDD Workflow (modu-ai/moai-adk, 1.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains TDD?

RafaelGB (a GitHub user) maintains it in RafaelGB/Obsidian-ZettelFlow, which has 174 GitHub stars. The repository holds 9 skills in this directory. The repository was last updated on October 8, 2026.

Source: RafaelGB/Obsidian-ZettelFlow on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.