My brother recently confessed that he sometimes has improper thoughts (some are really bad) for Allah. My brother is mentally unfit and having those thoughts brings him fear (he drenches in fear) and he repents but he is afraid he cannot stop them. Bear in mind, these thoughts spurt out in his mind, they are not intentional. He says ishtighfar 133 times daily which have been helpful in bringing peace, but have not been able to stop those thoughts from coming. He is a good person, charitable and sorts.
Will he be punished for these thoughts? Is there anything than can be done to purify his mind? Is he being tested? Will Allah punish someone for sins committed he cannot control?