mcpField
T
testing

testing

github.com/potetoTesting & quality571240 installsUpdated 32w ago
Repository

About testing

A test-driven skill for Noodle developers, centered on reproducing bugs before fixing them. It describes fixture-based tests and commands for running, checking, and maintaining the test suite.

Key features

  1. 01Bug-first test workflow
  2. 02Directory-based test fixtures
  3. 03Bug fixture guidance
  4. 04Commands for tests and checks
  5. 05Fixture hash and output maintenance

Use cases

  1. 01Reproduce a bug before changing code
  2. 02Add a fixture-based regression test
  3. 03Run package or integration tests
  4. 04Check fixtures and project quality

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/poteto/noodle --skill testing

After installing, type/testingin Claude Code to confirm it loaded.

Bundled filesreferences/fixtures.md

Details

From the project README

Testing

Test-driven by default. Prove the problem before solving it.

Core Workflow: Bug First

  1. Reproduce — Run the failing scenario and observe the actual behavior
  2. Write a failing test — Minimal reproduction as a test case
  3. Commit the failing test — Use Skill(commit) with message like test: reproduce #issue-description
  4. Fix the code — Only now attempt the fix
  5. Verify — Run pnpm test and confirm the test passes
  6. Commit the fix — Separate commit from the test

This applies to all bug fixes. The failing test proves the bug exists and prevents regressions.

Fixture Tests

Noodle uses directory-based fixtures in testdata/. Read references/fixtures.md for full format, helper API, and code patterns.

Creating a New Fixture
./scripts/scaffold-fixture.sh <package-dir> <fixture-name> [state-count]

Fill in the generated input.json/input.ndjson and expected.md, then:

pnpm fixtures:hash:sync
Bug Fixtures

See references/fixtures.md for full bug fixture format (frontmatter fields, expected error sections, and the fix workflow).

Key Commands

CommandPurpose
pnpm testRun all tests
pnpm test:shortSkip integration tests
pnpm checkFull local CI (test + vet + lint + fixtures)
pnpm bugsList fixtures marked as known bugs
pnpm fixtures:loopVerify loop fixtures match expected
pnpm fixtures:loop:recordRegenerate loop fixture expected output
pnpm fixtures:hashVerify fixture input hashes
pnpm fixtures:hash:syncUpdate fixture input hashes
pnpm vetRun go vet
pnpm lint:archArchitecture lint (file sizes, legacy patterns)

Running Specific Tests

# Single package
go test ./loop

# Single test
go test ./loop -run TestLoopDirectoryFixtures

# Bypass cache
go test -count=1 ./parse

# With race detector
go test -race ./...

# Verbose
go test -v ./tui

Integration Tests

Long-running or external-dependency tests use testing.Short():

if testing.Short() {
    t.Skip("skipping integration test in short mode")
}

pnpm test:short skips these. pnpm test runs everything.

Comments

Markdown supported