SyncOnAI360

Salesforce glossary

What is Apex test coverage?

The share of Apex lines run by tests; 75% is required for production

  • Also: code coverage

Definition

Apex test coverage is the percentage of Apex code lines executed by the org's tests. Salesforce requires at least 75% coverage to deploy Apex to production, and every trigger must have some coverage. Coverage measures lines run, not whether behaviour is correct.

01Why it matters

Apex test coverage in practice

Coverage failures usually appear on deploy day, and the quick fix is tests that run lines without checking anything. Tests that assert behaviour are what actually protect the org.

02In SyncOnAI 360

How it shows up in the product

SyncOnAI 360 reads coverage from the org's last test run and says Not recorded when there is none, rather than 0%. Every proposal with Apex runs a coverage check before deploy day, and the audit flags classes with missing or weak tests.

Start in 5 minutes. No card required.

Connect your Salesforce org. Run your first health scan. Ask your first question. See what you've been missing.

  • Anthropic
  • OpenAI