TestSetUp method in apex test classes
@testsetup annotation in test class method Test classes are an important part of overall SDLC in Salesforce. We as a developer have to write the test classes very often, and we need to create the test data as well, to have our test class executed successfully. We’ll cover a new concept […]
What is Test class in Salesforce Apex
We know that Testing is an important part of SDLC(Software Development Life Cycle). In Salesforce when you want to deploy classes or Triggers from one org to another org, Salesforce requires at least 75% of your code to be covered by the test classes. So, Salesforce wants to make sure […]
Lightning Component(Aura) To Display Contacts Related To Particular Account
Step 1: Create Apex Class for fetching Contact Details : We need to use the notation “@AuraEnabled” before the method to make it available in the Aura component.public class AccountClass { @AuraEnabled public static list<Contact> getRelatedList(Id recordId) { List<Contact> Conlist = [Select id, name,firstname,lastname,Title,Email,Phone from Contact where AccountId=: recordId ]; return Conlist; }}Step 2: Create a New Lightning […]