+ Start a Discussion
rajmulrajmul 

how to pass values to testmethod

hi   everybody..can anyone help me to write test class and how to pass values to variable objstdwrap?? here i want to send null values..

 

public class stdcont

{

stdWrapper objstdWrap = stdResults.get(stn);

if( obstdjWrap != NULL )
{    

 

some code logic  here..

}

}

 

thanks in advance.

regards

rajmul

 

Best Answer chosen by Admin (Salesforce Developers) 
GemMaddyGemMaddy

You can create properties in the class to set and get value of the required variables. From the test class, you create instance of the class and use set property method.

 

All Answers

GemMaddyGemMaddy

You can create properties in the class to set and get value of the required variables. From the test class, you create instance of the class and use set property method.

 

This was selected as the best answer
rajmulrajmul
Thank u Gem..i got it..