laravel-testing
Skill by AsyrafHussin
Guides an AI assistant through writing Laravel 13 tests with Pest PHP 4 or PHPUnit 12. It is for developers writing feature tests, unit tests, or other test code in a Laravel application.
Install laravel-testing
Built from the published package, never by AI.
git clone --depth 1 https://github.com/AsyrafHussin/agent-skills /tmp/agent-skills && mkdir -p ~/.claude/skills && cp -r /tmp/agent-skills/skills/laravel-testing ~/.claude/skills/laravel-testingRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/AsyrafHussin/agent-skills /tmp/agent-skills && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/agent-skills/skills/laravel-testing ~/.gemini/antigravity-cli/skills/laravel-testingAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
laravel-testing is an agent skill that guides an AI assistant through writing tests for Laravel 13 applications. It supports both Pest PHP 4 and PHPUnit 12 and contains 24 rules across 6 categories: HTTP and feature tests, model factories, database assertions, faking services, authentication testing, and test organisation patterns. Before writing test code, the skill tells the assistant to check composer.json and tests/Pest.php to detect which framework the project uses.
The skill includes a syntax comparison table for Pest and PHPUnit and essential examples for both. Individual rule files hold bad and good examples, and the full compiled guide is in AGENTS.md. It is aimed at developers writing feature tests, unit tests, or any test code in a Laravel application. The source states PHP 8.3 or later and is published under the MIT license.
Written from the project's SKILL.md and checked against it.
What it can do
- HTTP and feature testsArrange, act, assert patterns, response assertions and RefreshDatabase guidance.
- Model factoriesDefining factories with typed fake data, states, sequences and relationships.
- Database assertionsassertDatabaseHas, assertModelExists, assertDatabaseMissing and soft delete checks.
- Faking servicesMail, Queue, Notification, Event and Storage fakes, plus AI agent, media and data fakes.
- Authentication testingactingAs() for session tests and Sanctum::actingAs() for API token tests.
- Test organisationdescribe/it blocks, datasets, and hooks in Pest or test classes and setUp in PHPUnit.
- Framework detectionChecks composer.json and tests/Pest.php to decide between Pest and PHPUnit syntax.
What you need
- PHP 8.3 or later
- Laravel 13.x
- Pest PHP 4.x or PHPUnit 12.x
Try asking
- Write a Pest feature test for creating a post as an authenticated user.
- Add a factory state for a trashed user and show how to test it.
- Show how to fake Mail and assert a mailable was sent to a user.
Good to know
- AI agent and media fakes are marked as Laravel 13+ features.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/laravel-testing/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to laravel-testing
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
laravel-testing: common questions
Does laravel-testing work with Pest or PHPUnit?
It supports both Pest PHP 4 and PHPUnit 12. The skill tells the assistant to detect which one the project uses before writing tests.
Which Laravel version does this skill target?
The source targets Laravel 13.x and states that PHP 8.3 or later is required.
Where are the detailed rules and examples?
Each rule has its own file with bad and good examples. The full compiled guide is in AGENTS.md.
How do I install laravel-testing?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is laravel-testing free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is laravel-testing safe to use?
It scores 76 of 100. Grades: maintenance A, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to laravel-testing?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
