Hi friends, As promised, the followup for the question about how to get test coverage on an attribute-only class is that: 1. You need to hand-declare a default constructor when writing up the class (don't just let it be implicit from Salesforce's side). 2. Then you need to write a unit test that explicitly instantiates the object. 3. For quality assurance (rather than for code coverage), it's not a bad idea to also do some setting of get/set-able attributes and verify that their values are what you set them to. Solution by @latentfuss -- THANK YOU! - Katie Kodes ------- KatieKodes katieKodes.com/summer19 @KatieKodes
Hi please upload 2nd episode of this training.... I couldnt attend 2nd session due to some problems... please upload the second episode as soon as possible
Hi friends,
As promised, the followup for the question about how to get test coverage on an attribute-only class is that:
1. You need to hand-declare a default constructor when writing up the class (don't just let it be implicit from Salesforce's side).
2. Then you need to write a unit test that explicitly instantiates the object.
3. For quality assurance (rather than for code coverage), it's not a bad idea to also do some setting of get/set-able attributes and verify that their values are what you set them to.
Solution by @latentfuss
-- THANK YOU!
- Katie Kodes
-------
KatieKodes
katieKodes.com/summer19
@KatieKodes
How I Can send a variable with a type Apex-Defined to subflow ? Or this impossible?
Hi please upload 2nd episode of this training.... I couldnt attend 2nd session due to some problems... please upload the second episode as soon as possible