Every approach has tradeoffs, including where Nimbus falls short. Nimbus does not replace a Salesforce org. It keeps the org out of the edit-and-test cycle. Final validation still happens on the platform.
Looking for a single-page deep dive? Nimbus vs scratch orgs · vs ApexMocks · vs Apex Replay Debugger · vs sf apex run test · and deployment suites
| Nimbus | Scratch Orgs | Dev Sandboxes | |
|---|---|---|---|
| Test speed | Milliseconds | 2-10 minutes | 2-10 minutes |
| Setup time | nimbus init | 15-30 min to push source + packages | Hours to provision, admin-controlled refresh cycles |
| CI/CD support | No org - JUnit/Cobertura XML | Needs org + credentials | Needs org + credentials |
| Platform accuracy | Real execution with fidelity gaps | Full platform fidelity | Full platform fidelity |
| Isolation | Per-test DB rollback | Per-developer org, fresh per run, not persistent | Shared org, shared state |
| Debugging | Live breakpoints, step-through | Replay Debugger (after execution) | Replay Debugger (after execution) |
| IDE integration | VS Code, IntelliJ, Dev UI | VS Code (deploy-based) | VS Code (deploy-based) |
| Stub API / mocking | Supported locally | Supported (needs org) | Supported (needs org) |
| Flow execution | Record-triggered, autolaunched, platform events (not all types) | Full platform | Full platform |
| Async Apex | @future, Batchable, Queueable, Schedulable | Full support | Full support |
| Sharing rules | OWD, role hierarchy, groups and share rows enforced under System.runAs; sharing rules not evaluated | Full enforcement | Full enforcement |
| Declarative rules | Validation, duplicate, assignment and workflow rules, processes and approval processes run; sharing rules do not | Full platform | Full platform |
| Final validation | Org still required before production | This is the validation | This is the validation |
| Mutation testing | Built-in (Pro) | Not available | Not available |
| UI testing | Not possible | Full browser testing | Full browser testing |
| Requires an org | No | Yes | Yes |
Best for: inner dev loop, CI merge gates, AI-assisted development
Nimbus runs a complete Apex interpreter locally with an embedded database. SOQL executes as real SQL, triggers fire on DML, flows run from your .flow-meta.xml files, and each test runs in an isolated transaction. It needs no org, no internet connection, and no credentials.
Nimbus supports the Apex Stub API locally, so existing ApexMocks tests run without changes. You can also skip the mocks and test against a real local database, where the queries, DML and triggers execute, at millisecond speed.
Debugging is live: set breakpoints, step through Apex line by line, inspect variables with full type information, in your editor rather than in Setup with a debug log. Structured execution traces show every method, query, and trigger with precise timing.
What's not replicated yet: sharing rules and UI testing. For those, complement with scratch org or sandbox testing.
Best for: pre-deployment validation, full platform feature verification
Scratch orgs provide full Salesforce platform fidelity. Every feature works exactly as it would in production - sharing rules, governor limits, async processing, UI rendering. Each developer gets their own isolated org, so there's no shared state between devs.
The tradeoffs: DevHub orgs are limited to 100 active scratch orgs and 200 per day. They're not persistent, so they're not great for long-running integration workflows. Setting up a scratch org for a complex codebase (pushing source, installing packages) takes 15-30 minutes. And they require credentials in CI.
Best for: UAT, staging, manual QA
Sandboxes offer full platform fidelity and are persistent; unlike scratch orgs, they stay around between sessions. Full Copy and Partial Copy sandboxes can include real production data; Developer and Developer Pro sandboxes are metadata-only.
The tradeoffs: multiple developers share a single sandbox, so test data bleeds between developers and test runs. Refresh cycles are limited and admin-controlled. They are not practical for the rapid edit-test-debug cycle.
Use Nimbus for the 80% of tests that exercise business logic, SOQL, triggers, and class behavior. These are the tests you run hundreds of times a day. Millisecond feedback here changes how you work.
Use scratch orgs for the 20% that require full platform features: complex sharing rules and UI testing. Run these as a pre-deployment verification step rather than on every edit.
Already using ApexMocks? Nimbus supports the Stub API, so your existing mocked tests run locally without changes. You can also add tests that use real SOQL and real DML alongside them, at the same speed and without an org.
And when it's time to ship, Nimbus runs the deployment too: nimbus deploy gates the deploy on your local tests, validates the exact payload in the org, then deploys it. See how assured deploys work.
Install in one line and run your first local Apex test in minutes.