+ Start a Discussion
Zabi MohammedZabi Mohammed 

Test class System.NullPointerException: Attempt to de-reference a null object


  when I am running a test class the pagereference method is having try, cactch blocks the MyPage.setRedirect(true)  is return outside of the chatch block so i am not able to cover this code please help me on this.

Marek Kosar_Marek Kosar_
Hi Zabi,
paste here your test class, it's hard to help without it.