Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Test Data Builders and Factories

    by Saizul Amin

    1

    This skill gives your agent a proven procedure plus scripts that check the facts, so you get the same correct answer every time, with exact fixes instead of vague advice.

    $4

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Test Data Builders and Factories

    Test Data Builders and Factories

    Example session with this skill installed

    Run the Test Data Builders and Factories skill on my project and give me a prioritised list of what to fix, with exact changes.

    • Read your context and instructions
    • Compiled the test data builders

    Here is what the Test Data Builders and Factories skill produced.

    Demo: real, unedited output of the skill's bundled script on a sample input from its test suite.

    Output

    """Deterministic test data builders. Generated by make_builder.py; edit freely."""
    
    from __future__ import annotations
    
    import itertools
    from datetime import datetime, timedelta, timezone
    from typing import Any
    
    EPOCH = datetime(2024, 1, 1, tzinfo=timezone.utc)
    _seq = itertools.count(1)
    
    def reset_sequences() -> None:
        """Call from a fixture so every test sees ids 1, 2, 3... regardless of order."""
        global _seq
        _seq = itertools.count(1)
    
    def build_entity(**overrides: Any) -> dict[str, Any]:
        """A valid Entity. Pass only the fields your test is about."""
        n = next(_seq)
        data: dict[str, Any] = {
            'Weird Key!': f"Weird Key {n}",
        }
        unknown = set(overrides) - set(data)
        if unknown:
            raise TypeError(f"build_entity: unknown field(s) {sorted(unknown)}")
        data.update(overrides)
        return data
    
    def build_entity_list(count: int, **overrides: Any) -> list[dict[str, Any]]:
        return [build_entity(**overrides) for _ in range(count)]
    

    What you do next

    1. Fix the highest-severity items first.
    2. Ask your agent to apply the fixes it suggests, then run the skill again to confirm.
    3. Keep the skill installed and re-run it whenever the project changes.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Create deterministic test data - a generator script turns a sample JSON object into a builder/factory for Python, TypeScript or PHP (sequence-based ids, emails and dates from a fixed epoch, nested builders, override only what the test needs), and a scanner finds non-determinism in tests and fixtures (unseeded random, Faker without seed, Math.random, Date.now, datetime.now, uuid4, rand, time()). Covers factory_boy, Faker seeding, fishery, @faker-js/faker, Laravel model factories, database seeding, fixtures vs builders, and per-test isolation.

    Who it's for

    Use when the user needs test data, factories, fixtures, seeds, fake data, object mothers or builders, or when tests fail because of random data, dates or ids.

    What's inside

    • Tested, offline Python script(s): nondeterminism_scan.py, make_builder.py (deterministic results, standard library only unless noted)
    • Reference guides: patterns.md, seeding.md, libraries.md
    • Step-by-step agent instructions in SKILL.md covering: When to use; When not to use; Workflow; Rules

    Why it's worth it

    Generic prompts guess. This skill gives your agent a proven procedure plus scripts that check the facts, so you get the same correct answer every time, with exact fixes instead of vague advice. See the real demo below.

    Works with every major AI agent

    Built on the open SKILL.md standard: Claude Code, Codex CLI, Cursor, VS Code Copilot, Gemini CLI, Windsurf and 20+ other agents.

    Requirements

    • Python 3.8+ for the bundled scripts
    • No API keys, no account, runs locally

    Open source: saizul/testing-qa-skills on GitHub (MIT licence, by Saizul Amin).

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse All Claude Skills.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Frequently Asked Questions

    Create deterministic test data - a generator script turns a sample JSON object into a builder/factory for Python, TypeScript or PHP (sequence-based ids, emails and dates from a fixed epoch, nested builders, override only what the test needs), and a scanner finds non-determinism in tests and fixtu...

    This skill uses the open SKILL.md standard. Use it through an MCP-compatible agent connected to Agensi, and check the compatibility information on this page for confirmed agents and required capabilities.

    Connect your AI agent to Agensi through MCP, then ask it to use Test Data Builders and Factories on your task. Your agent loads the latest approved version each time. Paid skills require a purchase or active subscription. Skill files are not available for download; your licence does not allow you to save, copy or export any part of a skill.