Agent skill · software engineering · davila7

test-detect

Auto-detect testing framework and run relevant tests. Identifies Jest, Vitest, Playwright, Cypress, pytest, Go test, and others. Can run all tests, specific file tests, or generate basic tests for new code. Usage - /test-detect, /test-detect src/auth/login.ts, /test-detect generate src/utils.ts

Why this skill is useful

Adds executable scripts for auto-detecting and running tests across multiple frameworks, which the AI wouldn't generate on its own.

What it needs

Requires cargo, cypress, go, jest, playwright, pytest, rspec, vitest installed locally. About 2k tokens when loaded. Last updated 2026-08-06. 30,138 stars on the source repository.

What this skill does

Test Detect Automatically detect the testing framework in the current project and run the right tests. Workflow Step 1: Detect the testing framework Check for these files in order (first match wins): Check Framework Run Command ------- ----------- ------------- vitest.config. exists OR vitest in devDeps Vitest npx vitest run jest.config. exists OR jest in devDeps Jest npx jest playwright.config. exists Playwright npx playwright test cypress.config. exists Cypress npx cypress run pytest.ini or conftest.py or pyproject.toml with [tool.pytest] pytest python -m pytest go.mod exists Go test go test ./... Cargo.toml exists Rust/cargo cargo test mix.exs exists ExUnit mix test Gemfile with rspec RSpec bundle exec rspec package.json has scripts.test npm test npm test Report the detected framework before proceeding. Step 2: Parse arguments Check $ARGUMENTS for the mode: No arguments or "all": Run the full test suite (Step 3) File path (e.g., src/auth/login.ts): Run tests for that file (Step 4) "generate" + file path (e.g., generate src/utils.ts): Generate tests (Step 5) Step 3: Run full test suite Run the detected test command. After completion: Report total tests, passed, failed, skipped If tests fail, show the first 3 failure messages with file:line references Suggest: "Run /test-detect <failing-file> to investigate a specific failure" Step 4: Run tests for a specific file Given a source file path, find its test file: Search strategy (try in order): 1. tests/<filename>.test.<ext> (Jest convention) 2. <filename>.test.<ext> (co-located) 3. <filename>.spec.<ext> (alternative convention) 4. test/<filename>test.<ext> (Go/Python convention) 5. tests/test<filename>.<ext> (pytest convention) 6. <filename>test.go (Go convention) Use Glob to find matches. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills davila7/test-detect

View the source on GitHub

Browse the @skills marketplace