Salesforce: I want to cover catch block of main class to have 100% code coverage. Can't seem to t...
Channel: Peter Schneider
Date: 06/08/2023

I want to cover catch block of main class to have 100% code coverage. Can't seem to throw exception. If anyone can help
I hope you found a solution that worked for you :)
 The Content (except music & images) is licensed under (https://meta.stackexchange.com/help/licensing)CC BY-SA  
Thanks to all those great people for their contributions!

 (salesforce.stackexchange.com/users/136260/sf-learner)SF Learner 
 (salesforce.stackexchange.com/users/127796/hemant-shukla)Hemant Shukla 
 A special thanks goes out to the (https://salesforce.stackexchange.com/questions/407193/i-want-to-cover-catch-block-of-main-class-to-have-100-code-coverage-cant-seem)Stackexchange community 
 
 I wish you all a wonderful day! Stay safe :)
 
  apex apextestrunresult soql code-coverage try-catch