You need to sign in to do that
Don't have an account?
Test RunAll error
Hello there,
I have this trigger,
trigger OnProjectUpdate on Project__c (after update, before update)
{
Triggers__c projectTrigger = Triggers__c.getInstance('OnProjectUpdate');
if( projectTrigger.Active__c )
{
OnProjectUpdate.createFeedbackForVolunteer(Trigger.new, Trigger.old);
OnProjectUpdate.updateVolunteerFields(Trigger.new);
}
}
Whenever, I do RunAll tests it gives error as follows:
System.DmlException: Insert Failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, these is already an item in this list with the name OnProjectUpdate: [name]
As I know this trigger is on UPDATE, it should not throw error on INSERT.
Please help.
Thanks in advance.
I have this trigger,
trigger OnProjectUpdate on Project__c (after update, before update)
{
Triggers__c projectTrigger = Triggers__c.getInstance('OnProjectUpdate');
if( projectTrigger.Active__c )
{
OnProjectUpdate.createFeedbackForVolunteer(Trigger.new, Trigger.old);
OnProjectUpdate.updateVolunteerFields(Trigger.new);
}
}
Whenever, I do RunAll tests it gives error as follows:
System.DmlException: Insert Failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, these is already an item in this list with the name OnProjectUpdate: [name]
As I know this trigger is on UPDATE, it should not throw error on INSERT.
Please help.
Thanks in advance.
Based on this thread:
https://developer.salesforce.com/forums/ForumsMain?id=906F00000008zF5IAI
it looks like it might be an issue with custom settings.
That helped me.