Platform Apex Test Generate
Use this skill when creating new Apex test classes, improving test coverage, debugging and fixing failing Apex tests, running test execution and coverage analysis, or implementing testing patterns for triggers, services, controllers, batch jobs, queueables, and integrations.
- CCM score
- 73 of 100
- skills.sh installs
- 7.7K
- GitHub stars
- 1.2K
- last updated
- Aug 21, 2026
Own this skill? Claim it
What it does
- Triggers on *Test.cls, *_Test.cls files, sf apex run test workflows, coverage reports, test-fix loops
- Do NOT trigger for production Apex code (use platform-apex-generate) or Jest/LWC tests
Install
$ npx -y skills add forcedotcom/sf-skills --skill platform-apex-test-generate -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
Generating Apex Tests
Generate production-ready Apex test classes and run disciplined test-fix loops with coverage analysis.
Core Principles
Details
- Repository
- github.com/forcedotcom/sf-skills
- Category
- Testing & QA
- First seen
- Jul 14, 2026
Questions
What does the platform-apex-test-generate skill do?
It generates and validates Apex test classes using TestDataFactory patterns, bulk testing with 251 or more records, mocking, and assertions. It also runs disciplined test-fix loops and coverage analysis for triggers, services, controllers, batch jobs and queueables. Use it when creating, fixing or improving Apex tests.
How do I install the platform-apex-test-generate skill?
Run npx -y skills add forcedotcom/sf-skills --skill platform-apex-test-generate -y in your project. That installs the skill so your agent can generate and fix Apex tests in the project.
Which category is platform-apex-test-generate in, and what sets it apart?
It sits in the Testing and QA category and ranks in the top 100 there. It covers Apex-specific test generation, while it does not handle production Apex code or Jest and LWC tests.
Does platform-apex-test-generate create test files for me?
Yes, for each test class it creates a Test.cls file and a matching cls-meta.xml file, and it adds a TestDataFactory class if the project has none. It follows Given/When/Then structure and the Assert class rules.
More from forcedotcom/sf-skills
All 78- Platform Apex Test Run7.5K
- Platform Apex Logs Debug7.4K
- Platform Soql Query7.4K
- Platform Metadata Deploy7.3K
- Platform Metadata Retrieve7.2K
- Platform Custom Field Generate7.1K
- Platform Docs Get7K
- Platform Permission Set Generate7K
- Dx Code Analyzer Run6.9K
- Platform Custom Object Generate6.9K
- Automation Flow Generate6.8K
- Experience Lwc Generate6.7K
- Platform Validation Rule Generate6.5K
- Platform Flexipage Generate6.5K
- Dx Org Manage6.4K
- Platform Data Manage6.4K
- Platform Sharing Rules Generate6.4K
- Platform Metadata Api Context Get6.3K
- Design Systems Slds Apply6.3K
- Design Systems Slds Validate6.1K
- Platform Custom Tab Generate6.1K
- Agentforce Generate6.1K
- Dx Code Analyzer Configure6K
- Platform Custom Application Generate6K
Similar to Platform Apex Test Generate
More Testing & QAplatform-apex-test-runforcedotcom/sf-skills7.5K installsApex test execution, coverage analysis, and test-fix loops with 120-point scoring.
sf-testingjaganpro/sf-skills1.5K installsTest execution, coverage analysis, and test-fix loops for Apex code, scored across six categories.
test-casesstellarlinkco/myclaude1.3K installsStructured test case generation from PRDs or requirements, covering functional, edge, error, and state scenarios.
testingmindrally/skills898 installsGeneral testing guidance covering isolation, data setup, coverage, and assertion clarity across frameworks and languages.