Agent skill · Audited from source
unit-tests
skill · bklit/bklit-uiMIT licenceAudited 23 Oct 2026 · source 3e61684b2303
Is it safe? Yes — SAFE, grade B (89/100). We read this skill's source at commit 3e61684b2303 and found no filesystem, network or shell access and no hard-coded secrets. What it does: Guardrails for adding unit tests in bklit-ui without over-testing. Use when the user mentions unit test, unit tests, tests, test coverage, add tests, write tests, vitest, jest, or asks whether something should be tested.
Cite
Cite this page
ModelsAtlas. “unit-tests (bklit/bklit-ui)”. Retrieved 23 Oct 2026. https://modelsatlas.com/skills/bklit/unit-tests
Trust audit
Audit 0.4.1 · source read 23 Oct 2026
SAFE means nothing in the source contradicts what the skill says it does. Grade B is shared by 13,985 of 14,816 audited skills.
What the source does
- FilesystemNone observedNo reads or writes in the source
- NetworkNone observedNo outbound calls in the source
- ShellNone observedNo commands run in the source
- DependenciesPinnedNothing floats
- SecretsNone foundNo keys in source
Five audit layers
| Layer | What we check | Result | Findings |
|---|---|---|---|
L0 Provenance | Repo owner, licence, archive status, activity | WARN | 1 |
L1 Static source | Secrets, path traversal, supply chain, hidden code | NA | 0 |
L2 Instructions | Prompt injection, authority framing, hidden directives | PASS | 0 |
L3 Inventory | The files and declarations match the source | PASS | 0 |
L4 Sandbox | Run in isolation and watch behaviour | SKIPPED why | 0 |
Gates applied: no behavioural pass.
Findings (1)
MEDIUMInventory / provenanceinv.symlink · .cursor/skills/turborepo
.cursor/skills/turborepo
- Why
- link not followed
- Fix
- —
Audit 0.4.1 · source sha 3e61684b2303 · 23 Oct 2026Report an issue or request a re-scan
Provenance
Who published it, and what the verdict is pinned to
- Publisherbklit GitHub organizationOwner of the repository this skill is read from
- Source folderbklit/bklit-ui/.agents/skills/unit-testsThe exact folder we audited
- LicenceMITAs the repository states it
- Commit pinned for this verdict3e61684b2303A new audit runs when the source changes
- Repository statusNot archivedPushed today
- Sandboxed runNot runSkills are read, not executed; layer L4 is skipped
What it tells the agent
Full source on GitHub ↗Its description: Guardrails for adding unit tests in bklit-ui without over-testing. Use when the user mentions unit test, unit tests, tests, test coverage, add tests, write tests, vitest, jest, or asks whether something should be tested.
---
name: unit-tests
description: |
Guardrails for adding unit tests in bklit-ui without over-testing. Use when the
user mentions unit test, unit tests, tests, test coverage, add tests, write tests,
vitest, jest, or asks whether something should be tested.
metadata:
internal: "true"
---
# Unit Tests (bklit-ui)
Read this skill before proposing or writing tests. **Default stance: fewer, higher-signal tests.**
---
## When to add tests
Add tests when they **lock in behavior that is easy to break silently**:
| Worth testing | Why |
|---------------|-----|
| Pure functions / modules | Stable inputs → outputs; fast; no DOM |
| Formatters, parsers, scale math, bounds | Regression on string/number output is user-visible |
| Codegen / export / registry helpers | Output shape is the contract |
| Non-obvious edge cases | Empty data, reversed ranges, clamping |
**Examples in this repo:** `chart-formatters.test.ts`, `highlight-segment-bounds.test.ts`, `animation.test.ts`, `apps/web/lib/studio/__tests__/*`.
---
## When NOT to add tests (unless explicitly requested)
Do **not** add tests just to increase coverage or “be thorough”:
| Skip | Why |
|------|-----|
| React component render smoke tests | visx, motion, portals → brittle; manual/docs check is cheaper |
| `memo()` / guard extractions (#65-style) | Structural perf refactors; output unchanged; RTL mount assertions are heavy |
| Default prop passthrough | `formatValue = intFmt` — types + formatter tests cover it |
| Third-party library behavior | Don’t re-test d3, visx, or React |
| Trivial getters / one-line wrappers | No regression signal |
| Snapshot entire chart SVG/JSX | High churn, low signal |
If the user asks “should we test X?” — **say no** when X falls in this table, and suggest a lighter alternative (pure helper test, manual check, CI build).
---
## Repo conventions
**Runner:** Node built-in test runner + `tsx` (not Jest/Vitest unless the repo adopts them later).
```bash
pnpm test # root — turbo runs packages with a test script
pnpm --filter @bklitui/ui test
cd apps/web && pnpm test
```
**Place tests:** `**/__tests__/**/*.test.ts` next to the code under test.
**Pattern:**
```ts
import assert from "node:assert/strict";
import { describe, it } from "node:test";
import { myFn } from "../my-module";
describe("myFn", () => {
it("handles empty input", () => {
assert.equal(myFn([]), expected);
});
});
```
**Equivalence tests** (preferred for formatters): assert shared module output matches the **previous inline** call (e.g. `toLocaleDateString` with same locale/options) so tests stay timezone-safe and prove no visual regression.
**New package test script:** add to `package.json`:
```json
"test": "node scripts/run-tests.mjs"
```
Use a small `scripts/run-tests.mjs` that collects `*.test.ts` from `__tests__` and invokes `node --import tsx --test` — shell globs break on Linux CI. Add `tsx` as a devDependency if missing. Wire into root `turbo.json` `test` task; CI runs `pnpm test`.
---
## Decision checklist (run before writing)
1. Is the logic **pure** or extractable to pure functions? → Test that. Consider extracting first.
2. Would a test fail on a **real user-visible bug**? → Good candidate.
3. Does it need **jsdom / RTL / Playwright**? → Stop; justify to user or defer to manual/visual check.
4. Did the user **ask** for tests? → Still apply this skill; don’t over-deliver.
5. How many cases? → **3–10 focused cases**, not exhaustive matrices.
---
## What to tell the user
When recommending tests, be explicit:
- **Add:** “Test `chart-formatters.ts` — pure, high regression value.”
- **Skip:** “Skip component tests for the memo split — no output change; build + manual chart docs are enough.”
- **CI:** Mention `pnpm test` in PR test plan when adding or changing tests.
---
## Anti-patterns
- Adding Jest/Vitest/Testing Library for a one-off without team buy-in
- Mocking entire chart context to assert `useMemo` call counts
- Testing implementation details (hook order, internal component names)
- Duplicating type-checker work (`expect(typeof x).toBe('function')`)
- Committing tests that only pass locally due to hard-coded timezone/locale stringsExcerpt, first 4,214 characters of SKILL.md, verbatim from the audited commit. It is text from someone else’s repository, quoted so you can judge it before your agent reads it.
Install
Pinned to the audited commit 3e61684
git clone https://github.com/bklit/bklit-ui git -C bklit-ui checkout 3e61684b2303
The author documents no install command, so this uses the repository directly. Our verdict covers commit 3e61684b2303 only.
Works in
The author has not said which agents this skill supports, and we have not tested it in any.
Audit history
Every audit, every source change
- ✓SAFE B 89 / 100
first audit · source
3e61684b2303
README badge
For maintainers · shows the latest audit
[](https://modelsatlas.com/skills/bklit/unit-tests/)
The badge shows our verdict and grade for this skill, and links back to this page. It changes when the audit does.
Similar skills
All coding & review skills →bklit/bklit-ui
Turborepo monorepo build system guidance. Triggers on: turbo.json, task pipelines, dependsOn, caching, remote cache, the "turbo" CLI, --filter, --affected, CI optimization, environment variables, internal packages,…
bklit/bklit-ui
bklit-ui monorepo contributors only — ship a chart or component from Studio prototype to production in packages/ui with docs and registry.
bklit/bklit-ui
Install, compose, theme, and animate Bklit UI charts (the @bklit shadcn registry) in a React / Next.js app. Use when the user wants a chart, graph, or data visualization: line, area, bar, live/streaming line, composed,…
bklit/bklit-ui
Turns plain-language chart design requests into exact Bklit UI (@bklit shadcn registry) components and props, styled to fit the host app. Use when someone describes how a chart should look rather than naming props, e.g.…
facebook/react
Use when you want to validate changes before committing, or when you need to check all React contribution requirements.
facebook/react
Use when you need to run tests for React core. Supports source, www, stable, and experimental channels.
Add this badge to your README
[](https://modelsatlas.com/skills/bklit/unit-tests/)
<a href="https://modelsatlas.com/skills/bklit/unit-tests/"><img src="https://modelsatlas.com/skills/bklit/unit-tests/badge.svg" alt="ModelsAtlas: SAFE B"></a>
Questions about unit-tests
What does the unit-tests skill do?
Is unit-tests safe to install?
What can unit-tests access on my machine?
How current is this page?
Sources
- github.com/bklit/bklit-ui/tree/main/.agents/skills/unit-tests — the audited source at commit 3e61684b2303 and every finding aboveObserved · 23 Oct 2026
Spotted something wrong? Report a correction · Methodology
Keep going in your AI
Opens with this page as the source. We add nothing else to the prompt.
- What does the unit-tests skill do?
- Is unit-tests safe to install?
- What can unit-tests access on my machine?