Hazrat Shaikh Moulana Muhammad Zakariyya (rahmatullahi ‘alaih) mentioned:

“Beloved friends! It is not something to be said, however I feel I should mention it to you. Undoubtedly, we are not pious people; nevertheless we endeavour to adopt the appearance of the pious and truthful. We have hope that through adopting the appearance of the pious and truthful, Allah Ta’ala will also favour us and will not deprive us of His grace. Look at the incident of Moosa (‘alaihis salaam) and Fir’oun. In the era of Fir’oun, the magicians confronted Nabi Moosa (‘alaihis salaam) (with the intention of opposing him). However on account of them imitating his clothing and outward appearance, Allah Ta’ala gave them taufeeq of embracing Islam and Allah Ta’ala favoured them. (Malfoozaate Hazrat Shaikh 1/107)

Source: Ihyaauddeen.co.za