Agent skill

Testing

by celeriant in celeriant/celeriant-db

How to write and run tests in Celeriant. An agent skill from celeriant/celeriant-db.

Apache-2.0Auto-check passedTesting & QA

Install Testing

skills CLI
$ npx skills add celeriant/celeriant-db --skill testing -a claude-code

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

GitHub CLI
$ gh skill install celeriant/celeriant-db testing --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/celeriant/celeriant-db.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/testing .claude/skills/testing && 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
testing
GitHub stars
114
Token cost
~951 tokens
SKILL.md length
246 words
Files
1
Skills in repo
13
Repo updated
First seen
Licence
Apache-2.0

At a glance

How to write and run tests in Celeriant. An agent skill from celeriant/celeriant-db.

  • Works in 4 steps: Create… → Add pub mod my_test; to lib.rs → Add a TestEntry to registry.rs with… → …
  • Tasks that involve Integration testing
  • SKILL.md covers Unit Tests, Integration Tests and Benchmarks
  • Calls cargo

What it does

Testing is an agent skill from celeriant/celeriant-db. How to write and run tests in Celeriant. Unit tests with glommiotest! macro, integration tests via the test runner with category registry, Criterion benchmarks. Use when creating tests or benchmarks.

Its SKILL.md is about 950 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 Integration testing and Unit testing. The repository describes itself as: Fast, distributed per-aggregate event log with strict ordering and optimistic concurrency control. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Integration testing
  • Tasks that involve Unit testing

Example prompts

  • “/testing”

Workflow steps

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

  1. Create celeriant_integration_tests/src/my_test.rs with pub async fn run() -> Result<(), Box>
  2. Add pub mod my_test; to lib.rs
  3. Add a TestEntry to registry.rs with name, description, estimated_secs, categories, and whether it requires distributed (MinIO + multi-node)
  4. Add the dispatch arm in main.rs dispatch_test(): "my_test" => my_test::run().await

What it can do on your machine

Read from SKILL.md and the folder at commit d071a6d. 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:

    • cargo

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

  • Network

    No URLs in SKILL.md.

    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

Testing loads about 951 tokens when it runs. Until then it costs about 52 tokens; SKILL.md has 246 words of instructions outside code blocks.

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

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 celeriant/celeriant-db at commit d071a6d, republished under its Apache-2.0 licence (© celeriant). 246 words, ~951 tokens.

Download SKILL.mdSave it as .claude/skills/testing/SKILL.md (or your agent's skills folder).
name
testing
description
How to write and run tests in Celeriant. Unit tests with glommio_test! macro, integration tests via the test runner with category registry, Criterion benchmarks. Use when creating tests or benchmarks.

Testing

Unit Tests

Async code needs a Glommio executor. Use the glommio_test! macro defined locally in test modules:

rust
macro_rules! glommio_test {
    ($body:expr) => {
        LocalExecutorBuilder::new(Placement::Fixed(0))
            .spawn(|| async move { $body })
            .unwrap()
            .join()
            .unwrap()
    };
}

#[test]
fn my_async_test() {
    glommio_test!({
        let result = some_async_fn().await;
        assert!(result.is_ok());
    });
}

The macro is defined per test module (not crate-wide). See celeriant_shard/src/shard_wal_sync.rs, celeriant_rotating_log/src/log_segment_file.rs, celeriant_watch/src/tests.rs for examples.

Test philosophy: test observable behavior, not implementation details. Understand the design spec before writing tests. Extract common helpers (test_dir(), test_config(), make_aggregate_key()). Descriptive function names (write_with_empty_events_returns_error).

Integration Tests

Single binary with a test runner and category-based registry. Not separate binaries.

Each test is a module with pub async fn run() that spawns real server processes via TestServer, connects with CeleriantClient, and gets a fresh temp dir. The runner dispatches via --run-test <name> as subprocess, capturing output to /tmp/celeriant_test_<name>.log.

Build First

Integration tests spawn the Celeriant server as a subprocess. Build it before running tests:

bash
cargo build -p celeriant --release
cargo build -p celeriant_wal_inspect --release   # some tests (e.g. stale_lease_restart_split_brain) shell out to it
Running
bash
# Run all standalone tests
cargo run -p celeriant_integration_tests --release -- --standalone

# Run a specific test
cargo run -p celeriant_integration_tests --release -- --test single

# Filter by category (AND)
cargo run -p celeriant_integration_tests --release -- --include core,correctness

# Filter by category (OR)
cargo run -p celeriant_integration_tests --release -- --include-or edge,invariant

# List matching tests without running
cargo run -p celeriant_integration_tests --release -- --standalone --list

# List all categories
cargo run -p celeriant_integration_tests --release -- --list-categories
Adding a New Integration Test
  1. Create celeriant_integration_tests/src/my_test.rs with pub async fn run() -> Result<(), Box<dyn std::error::Error>>
  2. Add pub mod my_test; to lib.rs
  3. Add a TestEntry to registry.rs with name, description, estimated_secs, categories, and whether it requires distributed (MinIO + multi-node)
  4. Add the dispatch arm in main.rs dispatch_test(): "my_test" => my_test::run().await

Categories: Core, Replication, Election, Fencing, Invariant, Edge, Correctness, Durability, Performance, Operations, Security, Schema, Compaction, Debug.

Benchmarks

Criterion for statistical measurement, Glommio for async execution. Use iter_custom with manual timing since Criterion's iter() doesn't work with async. Fresh Glommio executor per iteration for clean state. black_box to prevent optimisation.

Existing benchmarks live under celeriant_shard/benches/ and celeriant_wire/benches/. Look at them for patterns including wave-based arrival and concurrent spawn_local.

Baseline workflow:

bash
cargo bench --package celeriant_shard --bench aggregate_count_benchmark -- --save-baseline my_baseline
critcmp --export my_baseline > ./celeriant_shard/benches/my_baseline.json
critcmp my_baseline > ./celeriant_shard/benches/my_baseline.txt

© celeriant, Apache-2.0. 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/testing of celeriant/celeriant-db.

Open the folder on GitHubat commit d071a6d

Compare with similar skills

Testing 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.

Testing compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Testing this skillceleriant/celeriant-db114—~951Automated safety check: PassApache-2.0
JS-in-HTML Testingliaohch3/claude-tap3.3k—~924Automated safety check: PassMIT
Crosvm Testinggoogle/crosvm1.3k—~847Automated safety check: PassBSD-3-Clause
Add Acceptance Testtalkincode/toughradius691—~827Automated safety check: PassMIT
Testing Patternslangchain-ai/skills-benchmarks118—~447Automated safety check: PassMIT
Atmos Testscloudposse/atmos1.4k—~1.9kAutomated safety check: PassApache-2.0

Similar skills

  • JS-in-HTML Testing

    liaohch3/claude-tap

    Tests JavaScript embedded in an HTML file in two layers: pytest checks of the logic ported to Python, and Playwright runs in a real browser for the DOM.

    3.3k GitHub stars~924 tokensUpdated 15 days ago
    Testing & QAAuto-check passed
  • Crosvm Testing

    google/crosvm

    Official

    Skill to assist with running tests and managing test VMs in the crosvm repository.

    1.3k GitHub stars~847 tokensUpdated today
    Testing & QAAuto-check passed
  • Add Acceptance Test

    talkincode/toughradius

    Write CI-executable acceptance/integration tests for protocol or end-to-end changes (TR-F022).

    691 GitHub stars~827 tokensUpdated 4 days ago
    Testing & QAAuto-check passed
  • Testing Patterns

    langchain-ai/skills-benchmarks

    Official

    Unit testing and integration testing best practices. An agent skill from langchain-ai/skills-benchmarks.

    118 GitHub stars~447 tokensUpdated 16 days ago
    Testing & QAAuto-check passed
  • Atmos Tests

    cloudposse/atmos

    Author Atmos smoke tests, post-deployment stack checks, and integration tests using type: test, HTTP assertions, shell or script/interpreter checks, require gates, parallel dependencies, matrix…

    1.4k GitHub stars~1.9k tokensUpdated today
    Testing & QAAuto-check passed
  • Memstack Development Test Writer

    cwinvestments/memstack

    A skill your agent uses when the user says 'write tests', 'add tests', 'test coverage', 'unit tests', 'integration tests', 'component tests', 'mocking', 'edge cases', or needs to generate tests with…

    423 GitHub stars~3.7k tokensUpdated 11 days ago
    Testing & QAAuto-check passed

More from celeriant/celeriant-db

All 13 skills in this repo
  • Error Handling

    celeriant/celeriant-db

    Error handling patterns in Celeriant. An agent skill from celeriant/celeriant-db.

    114 GitHub stars~550 tokensUpdated 9 days ago
    Auto-check passed
  • Understanding Celeriant Structure

    celeriant/celeriant-db

    Celeriant codebase architecture, crate responsibilities, and how they fit together.

    114 GitHub stars~803 tokensUpdated 9 days ago
    Auto-check passed
  • Extract A Type

    celeriant/celeriant-db

    Refactor a named Rust type or its surrounding code with an agreed scope.

    114 GitHub stars~934 tokensUpdated 9 days ago
    Auto-check passed
  • Client Server Protocol

    celeriant/celeriant-db

    Celeriant's client-server protocol invariants, network behavior, failure modes, and shard routing.

    114 GitHub stars~1.6k tokensUpdated 9 days ago
    Auto-check passed
  • Database Architecture

    celeriant/celeriant-db

    Core architecture invariants for Celeriant. An agent skill from celeriant/celeriant-db.

    114 GitHub stars~1.5k tokensUpdated 9 days ago
    Auto-check passed
  • Glommio Locking Patterns

    celeriant/celeriant-db

    Locking patterns for Glommio's single-threaded async executors.

    114 GitHub stars~876 tokensUpdated 9 days ago
    Auto-check passed

Categories

Questions about Testing

What does Testing do?

How to write and run tests in Celeriant. An agent skill from celeriant/celeriant-db. Testing is an agent skill from celeriant/celeriant-db. How to write and run tests in Celeriant.

When should I use Testing?

Testing fits situations like: tasks that involve Integration testing; tasks that involve Unit testing.

How do I install Testing in Claude Code?

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

How do I install Testing in Codex?

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

Can I use Testing 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 celeriant/celeriant-db --skill testing -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/testing, .gemini/skills/testing, .github/skills/testing and .opencode/skills/testing in your project.

What does Testing need to run?

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

Does Testing access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Testing 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 Testing use?

Testing is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Testing use?

About 951 tokens (SKILL.md is roughly 3.8k 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 Testing?

Skills that share tags, products or a category with Testing: JS-in-HTML Testing (liaohch3/claude-tap, 3.3k stars), Crosvm Testing (google/crosvm, 1.3k stars), Add Acceptance Test (talkincode/toughradius, 691 stars) and Testing Patterns (langchain-ai/skills-benchmarks, 118 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Testing?

celeriant (a GitHub organization) maintains it in celeriant/celeriant-db, which has 114 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on September 28, 2026.

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