One of the major changes that I have seen in our society is the increased structuring of the community to minimize spiritual and intellectual challenges and threats. The following gemora seems to indicate that avoiding or going after challenges is a dispute amongst Amoraim.
Avoda Zara(17a): R. Hanina and R. Jonathan were walking on the road and came to a parting of ways, one of which led by the door of a place of idol-worship and the other led by a harlots’ place. Said the one to the other: Let us go [through the one leading] by the place of idolatry he inclination for which has been abolished.1 The other however said: Let us go [through that leading] by the harlots’ place and defy our inclination and have our reward. As they approached the place they saw the harlots withdraw2 at their presence. Said the one to the other: Whence didst thou know this?3 The other, in reply, quoted, She shall watch over thee, mezimmah [against lewdness], discernment shall guard thee.4
On the other hand the following gemora seems to be saying no one should seek out challenges.
Sanhedrnin (107a): Rab Judah said in Rab's name: One should never [intentionally] bring himself to the test, since David king of Israel did so, and fell. He said unto Him, ‘Sovereign of the Universe! Why do we say [in prayer] "The God of Abraham, the God of Isaac, and the God of Jacob," but not the God of David?’ He replied, ‘They were tried by me, but thou wast not.’ Then, replied he, ‘Sovereign of the Universe, examine and try me’ — as it is written, Examine me, O Lord, and try me.2 He answered ‘I will test thee, and yet grant thee a special privilege;3 for I did not inform them [of the nature of their trial beforehand], yet, I inform thee that I will try thee in a matter of adultery.’ Straightway, And it came to pass in an eveningtide, that David arose from off his bed etc.4 R. Johanan said: He changed his night couch to a day couch,5 but he forgot the halachah: there is a small organ in man which satisfies him in his hunger but makes him hunger when satisfied.
Any sources which discuss this issue would be appreciated.