Joseph, my son, thou hast become great; Joseph, my son, thou hast become great and mighty; the end (determined) on thee was (that thou shouldst) be mighty, because thou didst subdue thy inclination in the matter of thy mistress, and in the work of thy brethren. Thee will I liken to a vine planted by fountains of water, which sendeth forth her roots, and overrunneth the ridges of stone, and covereth by her branches all unfruitful trees; even so didst thou my son Joseph subject by thy wisdom and thy good works all the magicians of Mizraim; and when, celebrating thy praises, the daughters of princes walking on the high places cast before thee bracelets and chains of gold, that thou shouldst lift up thine eyes upon them, thine eyes thou wouldst not lift up on one of them, to become guilty in the great day of judgment.
Why Joseph Would Not Raise His Eyes to the Daughters of Egypt
Targum Pseudo-Jonathan on Genesis 49:22