Agent skill

Testing Linters

by r-lib in r-lib/lintr

Guidelines and conventions for writing unit tests for linters in the r-lib/lintr package using testthat.

Custom licenceAuto-check passedDevelopment

Install Testing Linters

skills CLI
$ npx skills add r-lib/lintr --skill testing-linters -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install r-lib/lintr testing-linters --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/r-lib/lintr.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/testing-linters .claude/skills/testing-linters && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
testing-linters
GitHub stars
1.3k
Token cost
~3.8k tokens
SKILL.md length
1,723 words
Files
1
Skills in repo
4
Repo updated
First seen
Licence
Custom licence

At a glance

Guidelines and conventions for writing unit tests for linters in the r-lib/lintr package using testthat.

  • Works in 10 steps: Constructing Package Fixtures… → Fuzz Testing & Syntax Permutations (#… → Writing expect_lint() Assertions → …
  • Modifying linter test files under tests/testthat/
  • SKILL.md covers 1. Constructing Package…, 2. Fuzz Testing & Syntax…, 3. Writing expect_lint()… and 4. Concise File Fixtures…, plus 6 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Testing Linters is an agent skill from r-lib/lintr. Guidelines and conventions for writing unit tests for linters in the r-lib/lintr package using testthat. Use this skill whenever creating or modifying linter test files under tests/testthat/.

Its SKILL.md is about 3.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Linting and formatting. The repository describes itself as: Static Code Analysis for R.

When your agent uses it

  • Modifying linter test files under tests/testthat/
  • Tasks that involve Linting and formatting

Example prompts

  • “Use the testing-linters skill to guideline and conventions for writing unit tests for linters in the r-lib/lintr package using testthat”
  • “/testing-linters”

Workflow steps

10 steps, taken from the step headings in SKILL.md.

  1. Constructing Package Fixtures (DESCRIPTION & NAMESPACE)
  2. Fuzz Testing & Syntax Permutations (# nofuzz)
  3. Writing expect_lint() Assertions
  4. Concise File Fixtures (withr::local_tempfile)
  5. Testing Document Structure & Literate Formats
  6. Rules Governing # nocov and Coverage Patches
  7. All tests must use the public API
  8. Robust Filesystem Paths & Cache Hashing on Windows
  9. Empirical Test Case Synthesis & Modular Grouping
  10. Failing Regression Tests for Reported Bugs & Review Findings

What it can do on your machine

Read from SKILL.md and the folder at commit 5f40339. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are r).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Testing Linters loads about 3.8k tokens when it runs. Until then it costs about 52 tokens; SKILL.md has 1,723 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~52
When it runs · the whole SKILL.md, loaded when a task matches
~3.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 1,723 words (~3,832 tokens).

“When writing or updating unit tests in tests/testthat/test-*.R, adhere to the following testing conventions and production-readiness standards:”

— opening of SKILL.md by r-lib, Custom licence
name
testing-linters

Read the full SKILL.md on GitHub

Files

Just SKILL.md in .agents/skills/testing-linters of r-lib/lintr.

Open the folder on GitHubat commit 5f40339

Compare with similar skills

Testing Linters next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Testing Linters compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Testing Linters this skillr-lib/lintr1.3k—~3.8kAutomated safety check: PassCustom licence
Go Pedantrychromedp/chromedp13k—~3.7kAutomated safety check: PassMIT
Kedro Babysitkedro-org/kedro11k—~4kAutomated safety check: PassCustom licence
Trellis Checkanjiemo/SunnyBeach1787 repos~666Automated safety check: PassApache-2.0
WooCommerce Dev Cyclewoocommerce/woocommerce11k3 repos~431Automated safety check: PassCustom licence
Adk Setupgoogle/adk-python22k—~993Automated safety check: NotesApache-2.0

Similar skills

  • Go Pedantry

    chromedp/chromedp

    This skill should be used when the user is writing Go code and needs guidance on Go-specific pedantry: error wrapping with fmt.Errorf and %w, interface design (accept interfaces return structs)…

    13k GitHub stars~3.7k tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Kedro Babysit

    kedro-org/kedro

    Run Kedro's local lint / format / type-check / tests on changed files (uses the project's pre-commit hooks, ruff, mypy, pytest, lint-imports, detect-secrets, Make targets — in the right venv), or…

    11k GitHub stars~4k tokensUpdated today
    DevelopmentAuto-check passed
  • Trellis Check

    anjiemo/SunnyBeach

    Comprehensive quality verification: spec compliance, lint, type-check, tests, cross-layer data flow, code reuse, and consistency checks.

    178 GitHub starsUsed in 7 repos~666 tokens
    DevelopmentAuto-check passed
  • WooCommerce Dev Cycle

    woocommerce/woocommerce

    Workflow for WooCommerce development: run PHP and JavaScript tests, lint and fix code style on the current branch, and follow guides for i18n and markdown.

    11k GitHub starsUsed in 3 repos~431 tokens
    DevelopmentAuto-check passed
  • Adk Setup

    google/adk-python

    Official

    Sets up a local ADK Python development environment in a git clone of the open-source adk-python repository: a uv virtual environment, all dependency extras, pre-commit hooks, and a first unit-test…

    22k GitHub stars~993 tokensUpdated today
    DevelopmentAuto-check: notes
  • Dep Validate

    blokadaorg/blokada

    A skill your agent uses to validate risky dependency bumps end to end as a local or cloud-launched agent.

    3.3k GitHub stars~5.7k tokensUpdated yesterday
    DevelopmentAuto-check: notes

More from r-lib/lintr

  • Guidelines and architecture for handling literate R documents (.Rmd, .qmd, .Rnw, .Rhtml) and source extraction in the r-lib/lintr package.

    1.3k GitHub stars~826 tokensUpdated today
    Auto-check passed
  • Xpath Style

    r-lib/lintr

    Guidelines and conventions for writing, composing, and formatting XPath expressions when building or refactoring linters.

    1.3k GitHub stars~4.3k tokensUpdated today
    Auto-check passed
  • Guidelines and best practices for creating, extending, and refactoring linters in the r-lib/lintr package.

    1.3k GitHub stars~5.1k tokensUpdated today
    Auto-check passed

Questions about Testing Linters

What does Testing Linters do?

Guidelines and conventions for writing unit tests for linters in the r-lib/lintr package using testthat. Testing Linters is an agent skill from r-lib/lintr. Guidelines and conventions for writing unit tests for linters in the r-lib/lintr package using testthat.

When should I use Testing Linters?

Testing Linters fits situations like: modifying linter test files under tests/testthat/; tasks that involve Linting and formatting.

How do I install Testing Linters in Claude Code?

Run `npx skills add r-lib/lintr --skill testing-linters -a claude-code`. Or copy the skill folder (.agents/skills/testing-linters in r-lib/lintr) into .claude/skills/testing-linters in your project. Claude Code loads it when a task matches its description.

How do I install Testing Linters in Codex?

Run `npx skills add r-lib/lintr --skill testing-linters -a codex`. Or copy the skill folder (.agents/skills/testing-linters in r-lib/lintr) into .agents/skills/testing-linters in your project. Codex loads it when a task matches its description.

Can I use Testing Linters in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add r-lib/lintr --skill testing-linters -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/testing-linters, .gemini/skills/testing-linters, .github/skills/testing-linters and .opencode/skills/testing-linters in your project.

What does Testing Linters need to run?

SKILL.md names no scripts, command-line tools or credentials: Testing Linters is instructions for the agent only.

Does Testing Linters access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Testing Linters safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Testing Linters use?

Testing Linters has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does Testing Linters use?

About 3.8k tokens (SKILL.md is roughly 15k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Testing Linters?

Skills that share tags, products or a category with Testing Linters: Go Pedantry (chromedp/chromedp, 13k stars), Kedro Babysit (kedro-org/kedro, 11k stars), Trellis Check (anjiemo/SunnyBeach, 178 stars) and WooCommerce Dev Cycle (woocommerce/woocommerce, 11k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Testing Linters?

r-lib (a GitHub organization) maintains it in r-lib/lintr, which has 1,296 GitHub stars. The repository holds 4 skills in this directory. The repository was last updated on October 8, 2026.

Source: r-lib/lintr on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.