In the Biblical Book of Job, God allows Satan to test Job to see if Job will remain loyal to God or not, and Satan does a thorough job of it! First, all of Job's animals are carried off by raiders or struck down by fire, and the servants tending them are killed. These animals represent much of Job's wealth, so he goes from a rich man to a poor man in one day. Next, Job's children all die when the house they are in blows down in a great wind. Finally, Job himself is stricken with sores all over his body.
Job presents a pathetic picture at this point. His wife turns on him. His three friends, who supposedly come to comfort him, do anything but. Another friend shows up and isn't any more comforting than the others. Job has hit rock bottom in a major way.
Yet Job never curses God. He laments his situation, certainly. He rues the day he was born. He wonders what he has done to deserve all this. He even questions God. But Job never curses God. He does not lose his faith. He remains loyal.
Thus Job passes the test. After rebuking Job for his whining and properly humbling him, God restores him. He clears up Job's sores. He gives Job twice as many animals and twice as much wealth as before. He gives Job seven sons and three daughters. Job lives to a ripe old age and is respected and loved by all.