
You can run Apex tests from the class file open in the editor window. If you’ve added methods or classes since the last time the Test view was populated, click the refresh icon at the top of the Apex Tests view for the updated list. To clear the test results, click the refresh icon at the top of the Apex Tests view (hover text: Refresh Tests). If you click the name of a failed test method, you jump to the line where the failure occurred. To jump to the definition of a test class, a test method that passed, or a method that you haven’t run yet, click its name. To see the details of your test runs, hover over the name of a test class in the Side Bar.



If the Test view is empty, check if the Java setup is configured correctly. If you don’t see this icon, make sure that the project contains an sfdx-project.json file in its root directory. To access the Test view, click the beaker icon ( ) in the Activity Bar on the left side of the VS Code editor. The Test view in the Side Bar provides several features such as LWC Tests and Apex Tests. Apex extension allows you to run Apex tests to verify the functionality of your code.
