You need to sign in to do that
Don't have an account?

not sure how to test Boolean part of class
this is where I cannot get coverage
private boolean updateSystems() { boolean result=true; if (null!=systems) { //from here
List<System__c> updSys=new List<System__c>(); try { update systems; } catch (Exception e) { String msg=e.getMessage(); integer pos; // if its field validation, this will be added to the messages by default if (-1==(pos=msg.indexOf('FIELD_CUSTOM_VALIDATION_EXCEPTION, '))) { ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.INFO, msg)); } result=false; } } return result; }
Can you please post the test class lines where you are calling this method. I don't see anything which cannot be covered here in your method. Your method is private and cannot be accessed outside but that must be getting called somewhere from your code only. You must call that code to cover your use case.