Christians can withstand temptations when they focus on the goodness of God.
12 Blessed is the man who remains steadfast under trial, for when he has stood the test he will receive the crown of life, which God has promised to those who love him. 13 Let no one say when he is tempted, “I am being tempted by God,” for God cannot be tempted with evil, and he himself tempts no one. 14 But each person is tempted when he is lured and enticed by his own desire. 15 Then desire when it has conceived gives birth to sin, and sin when it is fully grown brings forth death.
16 Do not be deceived, my beloved brothers. 17 Every good gift and every perfect gift is from above, coming down from the Father of lights, with whom there is no variation or shadow due to change. 18 Of his own will he brought us forth by the word of truth, that we should be a kind of firstfruits of his creatures.