Sahih Muslim 2283
Abu Musa reported Allah's Messenger (ﷺ) as saying:
The similitude of mine and of that with which Allah sent me is that of a person who came to us and said: O people, I have seen an army with my eyes and I am a plain warner (and issue you warning) that you should immediately manage to find an escape. A group of people from amongst them paying heed (to his warning) fled to a place of protection and a group amongst them belied him and the morning overtook them in their houses and the army attacked them and killed them and they were routed. And that is the similitude of the one who obeyed me, followed with which I had been sent and the similitude of the other is of one who disobeyed and belied me and the Truth with which I have been sent.
حَدَّثَنَا عَبْدُ اللَّهِ بْنُ بَرَّادٍ الأَشْعَرِيُّ، وَأَبُو كُرَيْبٍ - وَاللَّفْظُ لأَبِي كُرَيْبٍ - قَالاَ حَدَّثَنَا 
 أَبُو أُسَامَةَ، عَنْ بُرَيْدٍ، عَنْ أَبِي بُرْدَةَ، عَنْ أَبِي مُوسَى، عَنِ النَّبِيِّ صلى الله عليه وسلم قَالَ
 ‏
"‏ إِنَّ مَثَلِي وَمَثَلَ مَا بَعَثَنِيَ اللَّهُ بِهِ كَمَثَلِ رَجُلٍ أَتَى قَوْمَهُ فَقَالَ يَا قَوْمِ إِنِّي رَأَيْتُ الْجَيْشَ
 بِعَيْنَىَّ وَإِنِّي أَنَا النَّذِيرُ الْعُرْيَانُ فَالنَّجَاءَ ‏.‏ فَأَطَاعَهُ طَائِفَةٌ مِنْ قَوْمِهِ فَأَدْلَجُوا فَانْطَلَقُوا
 عَلَى مُهْلَتِهِمْ وَكَذَّبَتْ طَائِفَةٌ مِنْهُمْ فَأَصْبَحُوا مَكَانَهُمْ فَصَبَّحَهُمُ الْجَيْشُ فَأَهْلَكَهُمْ وَاجْتَاحَهُمْ
 فَذَلِكَ مَثَلُ مَنْ أَطَاعَنِي وَاتَّبَعَ مَا جِئْتُ بِهِ وَمَثَلُ مَنْ عَصَانِي وَكَذَّبَ مَا جِئْتُ بِهِ مِنَ الْحَقِّ
 ‏"‏ ‏.‏