Skip to content
Back to skills

Cairo Test Organization

ASecurity

Explain Cairo test organization for unit vs integration tests, tests directory layout, and shared helpers; use when a request involves structuring tests across files or crates in Cairo.

  • 2 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 27, 2026
testingtestingapi

Works with

  • api

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 27, 2026

npx -y skills add David-Li0406/meta-skill-evloving --skill cairo-test-organization --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Cairo Test Organization?

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

Security grade badge for Cairo Test Organization
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/david-li0406-cairo-test-organization/badge)](https://www.skillsdirectory.com/skills/david-li0406-cairo-test-organization)

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: cairo-test-organization
description: Explain Cairo test organization for unit vs integration tests, tests directory layout, and shared helpers; use when a request involves structuring tests across files or crates in Cairo.
---

# Cairo Test Organization

## Overview
Explain how to structure unit and integration tests in Cairo projects.

## Quick Use
- Read `references/test-organization.md` before answering.
- Put unit tests alongside code in `src` with `#[cfg(test)]`.
- Put integration tests in a top-level `tests/` directory.

## Response Checklist
- Unit tests can access private functions via module scoping.
- Integration tests compile as separate crates per file and use the public API.
- Use `tests/lib.cairo` to make the tests folder a single crate with shared helpers.

## Example Requests
- "Where do integration tests live in Cairo projects?"
- "How do I share helpers across integration tests?"
- "Can unit tests call private functions?"

## Cairo by Example
- [Testing](https://cairo-by-example.xyz/testing)
- [Unit testing](https://cairo-by-example.xyz/testing/unit_testing)
- [Integration testing](https://cairo-by-example.xyz/testing/integration_testing)
- [Dev-dependencies](https://cairo-by-example.xyz/testing/dev_dependencies)

Files in this skill

  • SKILL.md1.2 KB
  • references/test-organization.md658 B

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.

Comments

Loading comments…