vf-testing

A testing guide for the Veryfront project using Deno's test runner and BDD-style tests. BDD means organising tests around observable behaviour, such as what a feature should do.

In plain words
What is it for?
Writing or debugging unit, integration, and end-to-end tests, choosing test locations, running the project's test commands, and following its test utilities and cleanup rules.
Why use it?
It helps tests remain isolated, properly cleaned up, and placed in the right location for their scope.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/veryfront/veryfront-code/vf-testing
Any agent
npx skills add veryfront/veryfront-code --skill vf-testing
Clone the repo
git clone --depth 1 https://github.com/veryfront/veryfront-code

Made for: Claude Code, Codex.

Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 958 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00036 $0.00958
Opus 5 $0.00018 $0.00479
Sonnet 5 $0.00007 $0.00192
Haiku 4.5 $0.00004 $0.00096

Measured 2d ago against content hash 0692a0157058, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

vf-testing 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 2d 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.

.claude/skills/vf-testing/SKILL.md · 130 lines

How it starts

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

Veryfront Testing Patterns

Overview

Veryfront uses Deno's test runner with BDD-style tests. Tests are either colocated unit tests or separate integration tests.

Core principle: Tests must be self-contained, use proper cleanup, and never share state.

Test Command

# Unit tests (colocated in src/)
VF_DISABLE_LRU_INTERVAL=1 SSR_TRANSFORM_PER_PROJECT_LIMIT=0 REVALIDATION_PER_PROJECT_LIMIT=0 NODE_ENV=production LOG_FORMAT=text deno test --no-check --allow-all --unstable-worker-options --unstable-net --parallel '--ignore=tests,src/ai/workflow/__tests__,src/cli/commands/*.integration.test.ts'

# All tests (unit + integration)
VF_DISABLE_LRU_INTERVAL=1 SSR_TRANSFORM_PER_PROJECT_LIMIT=0 REVALIDATION_PER_PROJECT_LIMIT=0 NODE_ENV=production LOG_FORMAT=text deno test --no-check --allow-all --unstable-worker-options --unstable-net

# Or use deno tasks
deno task test:unit
deno task test:integration
deno task test

File Placement

Type Location When
Unit test src/module/name.test.ts Pure functions, no I/O, no server
Integration test tests/integration/feature/name.test.ts Needs TestContext, server, filesystem
E2E test tests/e2e/ Full user flows (Playwright)
Index export test src/module/index.test.ts Verifies public API exports

Test Structure (BDD)

import { describe, it } from "#veryfront/testing/bdd";
import { assertEquals, assertThrows, assertRejects } from "#veryfront/testing/assert";

describe("ComponentName", () => {
  describe("methodName", () => {
    it("should return expected result when given valid input", () => {
      // Arrange
      const input = createInput();

      // Act
      const result = method(input);

      // Assert
      assertEquals(result, expected, "descriptive message");
    });
  });
});

Test Utilities

// Resource management (integration tests)
import { withTestContext } from "#veryfront/testing";

// TestContext provides:
// - context.allocatePort() — no hard-coded ports
// - context.createServer() — managed server lifecycle
// - Automatic cleanup on test end

// Filesystem isolation
import { withTempDir, withTempFile } from "#veryfront/testing";

// Environment isolation
import { withEnv } from "#veryfront/testing";

// Async helpers
import { delay, waitFor } from "#veryfront/testing";

// Cleanup registration
import { registerTestCleanup } from "#veryfront/testing";

Read the full file on GitHub · 130 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. 2d ago First seen · 130 lines · 36 tokens per session scan A 0692a0157058

Subscribe to this mod's changes

vf-testing is a skill published in the GitHub repository veryfront/veryfront-code (18 stars, last pushed 2d ago), licensed Apache-2.0. It adds 36 tokens to every session and 958 once invoked, about $0.0002 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-08-30.

Related

Other skills, from other repositories

rove

Use when controlling Rove tasks, parallel coding attempts, hosted agent sessions, task lifecycle, or the daemon-owned issue tracker from a shell. Also the ONLY channel for messaging another agent session on this machine — rove api send, never a peer/MCP side channel.

Sma1lboy/rove · 56 tokens

general-video

The fallback workflow for authoring custom HyperFrames video compositions at any length or format — longer or multi-scene pieces, brand / sizzle reels, montages, title cards, static loops, and freeform compositions. Input- and length-agnostic. If a specialized workflow clearly fits the input — a marketed product, a…

Sma1lboy/rove · 114 tokens

motion-graphics

Use when the user wants a short, design-led motion graphic where motion is the message: kinetic typography, stat or number count-up, chart/data-viz hit, logo sting, brand lockup, lower-third, callout, social overlay, animated headline/tweet/news item, motion poster, or quick captured-page highlight. Usually under 10s…

Sma1lboy/rove · 161 tokens

release

Autonomously cut a Rove (@sma1lboy/rove) release end-to-end — detect the semver bump from pending changesets (flagging an upstream minor you didn't intend), run the release gates, bump/tag/push via scripts/release.sh, then poll the GitHub Actions Release workflow with gh until npm publish completes, diagnosing CI…

Sma1lboy/rove · 155 tokens

file-issue

Turn a rough idea, a bug, or a batch of unsolved problems into well-structured GitHub issue(s) and file them with gh, auto-classifying type + labels from the content (recommend, then confirm) and following Rove's conventions (beginner-friendly framing, concrete file pointers, an acceptance checklist, zero AI/Anthropic…

Sma1lboy/rove · 184 tokens

hyperframes-cli

HyperFrames CLI dev loop. Use when running npx hyperframes init, add, catalog, capture, lint, validate, inspect, layout, snapshot, preview, play, render, publish, lambda, doctor, browser, info, upgrade, skills, compositions, docs, benchmark, telemetry, transcribe, or remove-background, or when troubleshooting the…

Sma1lboy/rove · 101 tokens