Overall meaning :
The Almighty says: In Allah’s Messenger you have a good model for everyone who hopes to earn Allah’s good pleasure, looks forward to meeting Him on the Day of Judgement, and remembers Allah much.
When the true believers saw the Confederates, they said, ‘This is the test and the subsequent victory that Allah and His Messenger have promised us; Allah and His Messenger have spoken the truth.’ The sight of the assembled Confederates around them and the severe test they faced only increased their faith and submission to Allah’s will.
Among the believers there are men who have been true to their covenants with Allah and are ready to lay down their lives for Allah’s sake. Some steadfastly and valiantly fought along with the Prophet until they were killed or survived to lead a life of total obedience and submission to Allah, and some are still awaiting its fulfilment without having changed or betrayed their pledges in the least.
Allah tests people with hardships and adversities to reward the true believers for their sincere faith and sternly punish the hypocrites if He wills (by causing them to die before repenting of their unbelief), or show them mercy by inspiring them to repent and turn to Him. Allah is All-Forgiving, All-Merciful.