The young people described in Surat al-Kahf devote themselves to Allah. They give up their families, marriages, children and businesses. There can be no marriage or business in the cave. No entertainment and no travel. There is just total concentration on religion. The community of Hazrat Mahdi (as) will also devote all its energies to religion. They will be active in a closed in area and always together with one another. It seems they will obtain results through intellectual activity.
(One of them said,) ‘When you have separated yourselves from them and everything they worship except Allah, take refuge in the cave and your Lord will unfold His mercy to you and open the way to the best for you in your situation.’ (Surat al-Khaf, 16)
O Abu Hurairah! This community [THE COMMUNITY OF HAZRAT MAHDI (AS)] will achieve the degree of the prophets by embarking on a hard and difficult road. THEY WILL CHOOSE HUNGER ONCE ALLAH HAS FED THEM, NAKEDNESS AFTER HE HAS CLOTHED THEM, AND THIRST AFTER HE HAS GIVEN THEM TO DRINK; THEY WILL PLACE THEIR HOPES IN ALLAH AND ABANDON THESE. THEY WILL EVEN ABANDON WHAT IS LAWFUL OUT OF FEAR OF HIS RECKONING. THEY WILL SHOW INTEREST IN THIS WORLD ONLY WITH THEIR BODIES, AND THEY WILL OCCUPY THEMSELVES WITH NOTHING BELONGING TO IT.
Even the angels and the prophets will be amazed at their obedience to our Lord. How happy they are! How happy they are! How I would have wished to see Allah unite me and them! ... (Ibn al-Arabi, Al-Wasaya , no: 198/2, p. 486a)