33-Surah Al-Ahzab ( The Combined Forces ) 15
And they had already promised Allah before not to turn their backs and flee. And ever is the promise to Allah [that about which one will be] questioned.
وَلَقَدْ كَانُوا عَاهَدُوا اللَّهَ مِن قَبْلُ لَا يُوَلُّونَ الْأَدْبَارَ ۚ وَكَانَ عَهْدُ اللَّهِ مَسْئُولًا
Quran's Tafhim ( explanation)
*27) That is, "They had felt regret at the weakness they had shown on the occasion of the Battle of Uhud and pledged to Allah that they would compensate for their error in any trial that they would confront in the future. But Allah cannot be deceived by empty words. He puts to one or the other test everyone who makes a pledge with Him so that his sincerity of intention or otherwise is found out. Therefore, just after two years of the Battle of Uhud, He made them confront an even more serious danger and discovered how far they were sincere in their pledge."