You need to sign in to do that
Don't have an account?
max_overload
Test class help. Getting a required field exception
Here's the code for the class:
@isTest private class JSLeadAssignmentTestClass { static testMethod void triggertest() { //Create new lead record Lead l = new Lead(firstname='test' , lastname='apex' , company='Oracle', LeadSource='Jigsaw'); insert l; }
When using the Apex Test Runner in Eclipse, I receive the error:
EXCEPTION_THROWN|[10,9]|System.DmlException: Insert failed. First exception on row 0; first error: REQUIRED_FIELD_MISSING, Required fields are missing: [Company]: [Company]
Any help would be greatly appreciated
that code works for me
do you have an insert trigger on Leads and what does it do?
Thanks for your reply, Nick. I do have a trigger on lead after insert/update. It pushes the lead through assignment rules and updates accordingly.