Salesforce
PDII · Question #68
PDII Question #68: Real Exam Question with Answer & Explanation
The correct answer is A. List<sObject> Is = Test.loadData (Lead.sObjectType, 'myTestLeads'); B. myDataFactory.createTestRecords (10). See the full explanation below for the reasoning.
Question
A developer needs test data for Apex test classes. What can the developer use to provide test data to the test methods? (Choose two.)
Options
- AList<sObject> Is = Test.loadData (Lead.sObjectType, 'myTestLeads');
- BmyDataFactory.createTestRecords (10)
- CDatabase.createTestRecords (10)
- DList<sObject> Is = Test.loadDat (Lead.sObjectType, $Resource + 'myTestLeads');
Community Discussion
No community discussion yet for this question.