testing

testing is a skill for Claude Code, Codex from lubusIN/frappe-skills. It costs 42 tokens per session (1,601 once invoked), scanned A, original, MIT.

Instructions for writing and running unit, integration, and interface tests for Frappe applications. Frappe is the application framework used by these projects, and a DocType is one of its data-model components.

In plain words
What is it for?
Use it to add test coverage, test DocType controllers, verify workflows and APIs, run interface tests, debug failures, or set up continuous integration for Frappe projects.
Why use it?
It helps check application behavior before changes reach users and provides commands for investigating failing tests. It also explains how to prepare a test site and run tests for an app, module, DocType, or file.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to add test coverage, test DocType controllers, verify workflows and APIs, run interface tests, debug failures, or set up continuous integration for Frappe projects.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/lubusin/frappe-skills/testing
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add lubusIN/frappe-skills --skill testing
Clone the repo
git clone --depth 1 https://github.com/lubusIN/frappe-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for testing

README.md
[![agentmods](https://agentmods.dev/badge/skills/lubusin/frappe-skills/testing/github.svg)](https://agentmods.dev/skills/lubusin/frappe-skills/testing)
Your own site
<a href="https://agentmods.dev/skills/lubusin/frappe-skills/testing"><img src="https://agentmods.dev/badge/skills/lubusin/frappe-skills/testing/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for testing

Your own site · 80×15
<a href="https://agentmods.dev/skills/lubusin/frappe-skills/testing"><img src="https://agentmods.dev/badge/skills/lubusin/frappe-skills/testing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 42 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,601 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00042 $0.01601
Opus 5 $0.00021 $0.00800
Sonnet 5 $0.00008 $0.00320
Haiku 4.5 $0.00004 $0.00160

Measured 11d ago against content hash 9bada8bad871, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

testing scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

testing/SKILL.md · 229 lines

How it starts

The opening of the file, as written. The whole thing — 229 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Frappe Testing

Write and run tests for Frappe applications using the built-in testing framework.

When to use

  • Writing unit tests for DocType controllers
  • Writing integration tests for workflows and APIs
  • Running existing test suites
  • Debugging test failures
  • Setting up CI pipelines for Frappe apps

Inputs required

  • App name to test
  • Site name for test execution
  • Specific module/DocType to test (optional)
  • Test environment (dev site, dedicated test site)

Procedure

0) Setup test environment

# Install dev dependencies
bench setup requirements --dev

# Ensure site is ready
bench --site <site> migrate

1) Run tests

# Run all tests for an app
bench --site <site> run-tests --app my_app

# Run tests for specific module
bench --site <site> run-tests --module my_app.my_module.tests

# Run tests for specific DocType
bench --site <site> run-tests --doctype "My DocType"

# Verbose output
bench --site <site> run-tests --app my_app -v

# Run single test file
bench --site <site> run-tests --module my_app.doctype.sample_doc.test_sample_doc

2) Write DocType tests

Create test_<doctype_name>.py alongside the DocType:

# my_app/doctype/sample_doc/test_sample_doc.py
import frappe
from frappe.tests.utils import FrappeTestCase

class TestSampleDoc(FrappeTestCase):
    def setUp(self):
        # Create test data
        self.doc = frappe.get_doc({
            "doctype": "Sample Doc",
            "title": "Test Document"
        }).insert()
    
    def tearDown(self):
        # Cleanup
        frappe.delete_doc("Sample Doc", self.doc.name, force=True)
    
    def test_creation(self):
        self.assertEqual(self.doc.title, "Test Document")
    
    def test_validation(self):
        doc = frappe.get_doc({
            "doctype": "Sample Doc",
            "title": ""  # Invalid - required field
        })
        self.assertRaises(frappe.ValidationError, doc.insert)
    
    def test_workflow(self):
        self.doc.status = "Approved"
        self.doc.save()
        self.assertEqual(self.doc.status, "Approved")

Read the full file on GitHub · 229 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 229 lines · 42 tokens per session scan A 9bada8bad871

Subscribe to this mod's changes

testing is a skill published in the GitHub repository lubusIN/frappe-skills (57 stars, last pushed 1mo ago), licensed MIT. It adds 42 tokens to every session and 1,601 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.