It is written (Psalm 11:5), “The LORD test the righteous, But the wicked and the one who loves violence His soul hates.”
Rabbi Jonathan said: “The potter does not try the vessels that have been made imperfectly, because he does not doubt that if he strike them even once, it will break them. But he tries the fair vessels; for however many times he may strike them, they will not be broken. So he strikes them to show the purchaser how strong and good they are.” Thus, God does not try the wicked but the righteous, and their trials show their virtue to the world. In this way “the Lord tried Abraham” (Gen. 22).
Rabbi Jose bar Chanina said: “This is like unto the weaver of a fabric. The more he strikes at it and cuts at it, the more it is praised, and the more does it acquire a good name. When he knows the fabric is bad, he does not dare to cut at it even once, for fear of tearing it.” Thus the Holy One, blessed be He, does not try the wicked, but the righteous.
Behold this may be likened to the goodman of the house who has two heifers; one healthy and strong, the other weak. On which of them will he put the yoke? Is it not upon the healthy and strong one? In like manner the Holy One, blessed be He, trieth the righteous.
Wisdom Of Israel, Edwin Collins