mcpbeat Sign in

Test Unbranded Emitter Agent Skill

> Build and test the @typespec/http-client-python emitter. Use this skill whenever the user wants to test their local changes to the emitter, run the generator test suite, check if their http-client-python changes are passing, or validate a fix. Triggers on phrases like "test the emitter", "run tests", "check if my changes in the emitter package.

1k tokens
context cost
the whole folder, loaded on every use
1
files
instructions only
0
copies elsewhere
how many repositories repackaged it
5811
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/microsoft/typespec --skill test-unbranded-emitter

The instruction itself

15 sections, as written by the author

Test Emitter Skill

Builds and tests @typespec/http-client-python to validate local changes.

Automatically regenerates if the generated code is stale.

Paths

All paths are relative to the http-client-python package root:

~/Desktop/github/typespec/packages/http-client-python

| Item | Path |

| --------------------- | ------------------------------------------------------- |

| Package root | ~/Desktop/github/typespec/packages/http-client-python |

| Emitter source | emitter/src |

| Generated (unbranded) | generator/test/unbranded/generated |

| Generated (azure) | generator/test/azure/generated |

| Regenerate marker | .last-regenerate |

Workflow

Step 1: Build the emitter

cd ~/Desktop/github/typespec/packages/http-client-python
npm run build

Check for TypeScript compilation errors. If the build fails, report the errors

to the user and stop — do not proceed to testing.

Step 2: Check if regeneration is needed

Regeneration is needed if ANY of these conditions are true:

  • Generated folder doesn't exist or is empty:
   cd ~/Desktop/github/typespec/packages/http-client-python
   
   if [ ! -d "generator/test/unbranded/generated" ] \
     || [ -z "$(ls -A generator/test/unbranded/generated 2> /dev/null)" ]; then
     echo "Unbranded generated folder is empty - regeneration needed"
   fi
   
   if [ ! -d "generator/test/azure/generated" ] \
     || [ -z "$(ls -A generator/test/azure/generated 2> /dev/null)" ]; then
     echo "Azure generated folder is empty - regeneration needed"
   fi
  • No regenerate marker file exists:
   if [ ! -f ".last-regenerate" ]; then
     echo "No regenerate marker - regeneration needed"
   fi
  • Emitter source files are newer than the marker:
   if [ -n "$(find emitter/src -newer .last-regenerate -type f 2> /dev/null | head -1)" ]; then
     echo "Emitter source changed since last regenerate - regeneration needed"
   fi

Step 3: Regenerate if needed

If any condition from Step 2 is true:

cd ~/Desktop/github/typespec/packages/http-client-python
echo "Regenerating test clients..."
npm run regenerate

After successful regeneration, update the marker:

touch .last-regenerate

If regeneration fails, report the error and stop.

If regeneration is NOT needed, inform the user:

> "Generated code is up to date (source unchanged since last regeneration). Skipping regenerate."

Step 4: Run the generator test suite

cd ~/Desktop/github/typespec/packages/http-client-python
npm run ci

This runs:

  • test:emitter - vitest unit tests for the emitter
  • ci:generator - pytest tests against generated code

The full CI can take several minutes. Keep the user informed that it's running.

Step 5: Report results

  • If tests pass: Confirm success and summarize any notable output (warnings, skipped tests, etc.)
  • If tests fail: Show the failing test names and error messages clearly.

Offer to help debug or investigate specific failures.

Integration with diff-upstream

Both skills share the regeneration marker system:

  • diff-upstream always regenerates and updates .last-regenerate
  • test-unbranded-emitter checks this marker and skips regeneration if fresh

Efficient workflow:

diff-upstream → test-unbranded-emitter

The second command will skip regeneration since diff-upstream just did it.

Standalone workflow:

test-unbranded-emitter

Will regenerate only if source changed since last run.

Notes

Regeneration takes time

npm run regenerate can take 2-3 minutes. The staleness check avoids this delay

when the user is iterating on test fixes (not emitter changes).

Test types

| Command | What it runs | Duration |

| ------------------------ | ------------------------- | ------------ |

| npm run test:emitter | vitest unit tests only | ~5 seconds |

| npm run test:generator | pytest only (no vitest) | ~2 minutes |

| npm run ci | vitest + pytest (full CI) | ~2-3 minutes |

This skill runs npm run ci (full CI). If the user wants just unit tests or

just pytest, they can ask specifically.

Known flaky test

The test server teardown sometimes fails with ProcessLookupError - this is a

pre-existing infrastructure issue, not a test failure. All actual tests may pass

even if you see this error at the end.

Force regeneration

If the user suspects stale generated code despite the marker, they can force

regeneration:

rm ~/Desktop/github/typespec/packages/http-client-python/.last-regenerate

Then run the skill again.

Gitignore

Ensure this entry is in the package's .gitignore:

.last-regenerate

Other skills for the same job

different authors, same section of the catalogue
Webapp Testing
by anthropics
vendor ×12

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.

6k tokens scripts
Finishing A Development Branch
by ZhanlinCui
×7

Use when implementation is complete, all tests pass, and you need to decide how to integrate the work - guides completion of development work by presenting structured options for merge, PR, or cleanup

1k tokens
Test Driven Development
by w95
×7

Use when implementing any feature or bugfix, before writing implementation code

2k tokens
Systematic Debugging
by ratacat
×7

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes

10k tokens scripts
Verification Before Completion
by ZhanlinCui
×6

Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always

1k tokens
Backtest Expert
by BaggaT236
×3

Expert guidance for systematic backtesting of trading strategies. Use when developing, testing, stress-testing, or validating quantitative trading strategies. Covers "beating ideas to death" methodology, parameter robustness testing, slippage modeling, bias prevention, and interpreting backtest results. Applicable when user asks about backtesting, strategy validation, robustness testing, avoiding overfitting, or systematic trading development.

15k tokens scripts
Adaptyv
by christophacham
×3

Cloud laboratory platform for automated protein testing and validation. Use when designing proteins and needing experimental validation including binding assays, expression testing, thermostability measurements, enzyme activity assays, or protein sequence optimization. Also use for submitting experiments via API, tracking experiment status, downloading results, optimizing protein sequences for better expression using computational tools (NetSolP, SoluProt, SolubleMPNN, ESM), or managing protein design workflows with wet-lab validation.

16k tokens
Aeon
by christophacham
×3

This skill should be used for time series machine learning tasks including classification, regression, clustering, forecasting, anomaly detection, segmentation, and similarity search. Use when working with temporal data, sequential patterns, or time-indexed observations requiring specialized algorithms beyond standard ML approaches. Particularly suited for univariate and multivariate time series analysis with scikit-learn compatible APIs.

19k tokens

How to use it

Copy the folder

Take microsoft/test-unbranded-emitter from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.