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

Advance Apex Specialist Step 8 - test coverage of Constants class....it shows 62%
Hi, I am facing issue with test coverage of Constants class....it shows 62%......It should automatically be covered by testing other classes except for this line of code because it cannot be executed in testing context--->
else {
if (stdPriceBook == null)
stdPriceBook = [select id, name from Pricebook2 where isStandard = true limit 1];
STANDARD_PRICEBOOK_ID = (stdPriceBook!=null)?stdPriceBook.id:'';
}
Below is the coverage shown...it is not showing blue for other lines nor it is showing red-----Any help would be appreciated

else {
if (stdPriceBook == null)
stdPriceBook = [select id, name from Pricebook2 where isStandard = true limit 1];
STANDARD_PRICEBOOK_ID = (stdPriceBook!=null)?stdPriceBook.id:'';
}
Below is the coverage shown...it is not showing blue for other lines nor it is showing red-----Any help would be appreciated