Skip to content
Back to skills

Add Assertion

ASecurity

Use to add a new assert_* function with tests.

  • 443 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 12, 2026
testingshellbashexpressdocumentation

Security analysis

A100/100

Scanned November 9, 2026

npx -y skills add TypedDevs/bashunit --skill add-assertion --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Add Assertion?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Add Assertion
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/typeddevs-add-assertion/badge)](https://www.skillsdirectory.com/skills/typeddevs-add-assertion)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: add-assertion
description: Use to add a new assert_* function with tests.
allowed-tools: [read, edit, write, shell, Grep, Glob]
---

# Add an assertion

Repository paths are relative to the repository root. Establish the assertion name, arguments, success and failure behavior, and messages from the request and sibling assertions; ask only for missing decisions. Record acceptance criteria and test inventory in `.tasks/YYYY-MM-DD-add-assertion-name.md` for nontrivial work.

1. Study the matching implementation under `src/assert/` and tests under `tests/unit/assert/`, including parameter validation, return codes, and message checks. `src/assert/index.sh` lists assertion modules.
2. Use focused RED, minimal GREEN, then REFACTOR for basic success, expected failure, and relevant edge cases (empty values, special characters, malformed input). Use `assert_assertion_passes`, `assert_assertion_fails`, or `assert_assertion_fails_with` from `src/assert/assertions.sh` where appropriate. Match existing output comparisons when needed; there is no `assert_fails`.
3. If adding a module, source it from `src/assert/index.sh`. Expose the public function through the existing module-loading pattern. Preserve Bash 3.0 parse compatibility and the existing public contract.
4. Document the public assertion's arguments, returns, and example in user-facing docs, update CHANGELOG, and complete the task file when used. Add code comments only for a constraint the code cannot express.
5. The main session runs the canonical quality gate once after the entire change set; delegates run only assigned focused checks. Verify success, failure, edge cases, module loading, and documentation before handing off.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.