Apex Unit Tests Basics # Part - 01
The apex testing framework on the Lightning Platform allows you to write and run tests for your apex classes and triggers. Adding Apex unit tests as part of your Salesforce development process ensures high-quality Apex code and that you meet the Apex delivery requirements. You can quickly test your Apex code with the Apex testing framework. In addition, Apex code can only be written in a Sandbox environment or a Developer org, not in production. Unit tests must cover at least 75% of your Apex code, and all of those tests must pass.