test-architecture

test-architecture is a skill for Claude Code from VersoXBT/claude-initial-setup. It costs 53 tokens per session (1,557 once invoked), scanned A, original, MIT.

A guide to organising automated tests, including reusable test data, setup files, database cleanup, and separation between test types.

In plain words
What is it for?
Use it when setting up tests, arranging test files, creating fixtures or factories, or isolating tests from one another.
Why use it?
It reduces flaky tests, shared-state problems, and hard-to-maintain test suites.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is import { validUser, adminUser } from '../fixtures/users'.

Part of the claude-initial-setup plugin — 75 skills, 15 commands, 14 agents, 2 hooks shipped together

Good fit Use it when setting up tests, arranging test files, creating fixtures or factories, or isolating tests from one another.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/VersoXBT/claude-initial-setup
agentmods
npx agentmods add skills/versoxbt/claude-initial-setup/test-architecture

Made for: Claude Code.

Or install claude-initial-setup, the plugin that ships this one along with the rest of its 75 skills, 15 commands, 14 agents, 2 hooks.

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 test-architecture

README.md
[![agentmods](https://agentmods.dev/badge/skills/versoxbt/claude-initial-setup/test-architecture.svg)](https://agentmods.dev/skills/versoxbt/claude-initial-setup/test-architecture)
Your own site
<a href="https://agentmods.dev/skills/versoxbt/claude-initial-setup/test-architecture"><img src="https://agentmods.dev/badge/skills/versoxbt/claude-initial-setup/test-architecture.svg" alt="Measured on agentmods" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,557 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.
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.00053 $0.01557
Opus 5 $0.00026 $0.00779
Sonnet 5 $0.00011 $0.00311
Haiku 4.5 $0.00005 $0.00156

Measured 4d ago against content hash a8fb66f89451, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

test-architecture 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 4d 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.

skills/testing/test-architecture/SKILL.md · 242 lines

How it starts

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

Test Architecture

Well-structured tests are maintainable, fast, and reliable. This skill covers how to organize test files, create reusable fixtures and factories, ensure test isolation, and configure test environments.

When to Use

  • User is setting up a new test suite or framework
  • User asks about test file organization or naming
  • User needs test fixtures, factories, or seed data
  • Tests are flaky due to shared state or ordering issues
  • User asks about database cleanup between tests
  • User needs test configuration (vitest.config, jest.config, conftest.py)

Core Patterns

Test File Organization

Co-locate tests with source files for discoverability:

src/
  services/
    auth.ts
    auth.test.ts          # Unit tests next to source
    billing.ts
    billing.test.ts
  routes/
    users.ts
    users.test.ts
test/
  integration/
    api.test.ts           # Integration tests in separate dir
  e2e/
    login.spec.ts         # E2E tests in dedicated dir
  fixtures/
    users.json            # Shared test data
  factories/
    user.factory.ts       # Data factories
  helpers/
    setup.ts              # Test setup utilities
    db.ts                 # Database helpers

Fixtures: Static Test Data

Fixtures are pre-defined data objects for predictable testing:

// test/fixtures/users.ts
export const validUser = {
  email: '[email protected]',
  name: 'Test User',
  role: 'member',
} as const

export const adminUser = {
  email: '[email protected]',
  name: 'Admin User',
  role: 'admin',
} as const

export const invalidUser = {
  email: 'not-an-email',
  name: '',
  role: 'unknown',
} as const

Usage in tests:

import { validUser, adminUser } from '../fixtures/users'

it('creates a user', async () => {
  const result = await createUser(validUser)
  expect(result.email).toBe(validUser.email)
})

Factories: Dynamic Test Data

Factories generate unique test data with sensible defaults. Override only what matters for each test:

Read the full file on GitHub · 242 lines

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. 4d ago First seen · 242 lines · 53 tokens per session scan A a8fb66f89451

Subscribe to this mod's changes

test-architecture is a skill published in the GitHub repository VersoXBT/claude-initial-setup (4 stars, last pushed 4mo ago), licensed MIT. It adds 53 tokens to every session and 1,557 once invoked, about $0.0003 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-09-03.

Related

Other skills, from other repositories

qa-testing-strategy

Risk-based test strategy for software delivery. Use when defining coverage, setting CI gates, managing flaky tests, choosing test layers, or establishing release criteria.

vasilyu1983/AI-Agents-public · 35 tokens

adept-writing-tests

How to write tests in the adept Go codebase — table-driven tests with testify, golden fixtures under testdata/, the cmd/adept e2e harness, temp-dir/HOME isolation, and coverage gates. Apply when adding or changing Go tests here. (matches: /test.go).

itaywol/adeptability · 61 tokens

sd-test

The disciplined test-recipe gate the generic agent runs for the software-delivery TEST step (/foundry:sd-test, step 8). A PROCEDURE — invoke the MERGED foundry-verify.py executor, read the run record's records whose phase == "testrecipe" (unit / integration / e2e), surface the profile's numeric coveragegate and advise…

lukasrepublic/agentic-foundry · 154 tokens

sota-testing

State-of-the-art software testing strategy and practice (2026) for designing test strategy, writing unit/integration/e2e tests, or auditing test suites. Covers suite shape (pyramid/trophy/honeycomb), test design quality (behavior-first, AAA, determinism, smells), test doubles (mocks/fakes/stubs), test data (builders…

martinholovsky/SOTA-skills · 239 tokens

agent-tester

Agent skill for tester - invoke with $agent-tester.

ruvnet/ruflo · 15 tokens

screen-reader-testing

Test web applications with screen readers including VoiceOver, NVDA, and JAWS. Use when validating screen reader compatibility, debugging accessibility issues, or ensuring assistive technology support.

wshobson/agents · 39 tokens