We find in the sunnah:
He who finds a rak'ah of the prayer, he in fact finds the prayer.
(In Sahih al-Bukhari and Sahih Muslim and elsewhere)
This is the criterion and basis on which we can decide whether or not we have prayed on time. This is also the basis that decides whether or not we have prayed in a congregation as one variations of the hadith which is also quoted in almost all hadith compilations includes the addition "with the imam".
So if a women's menses ended before the call (adhan or prayer time) for a prayer for the duration that she could safely pray one rak'ah this prayer is a due on her. The same rule applies for the beginning of the menses if the menses started after the call for a prayer for the duration that she could safely pray one rak'ah this prayer is a due on her. If the duration was too short then there's no harm and she doesn't need to pray it.
It is haraam for a menstruating woman to pray both obligatory and naafil prayers, and they are not valid if she does them. She does not have to do a particular prayer unless she was pure or became pure with enough time to perform a complete rak’ah, in which case she has to do the prayer, whether it is at the beginning of the time for it or at the end. An example of that happening at the beginning of the time for prayer is a woman who got her menses after the sun set but she had enough time to perform a complete rak’ah (but she did not do it), so when she becomes pure she has to make up that Maghrib prayer, because she had enough time to perform a complete rak’ah before she got her menses.
An example of that happening at the end of the time for prayer is a woman whose menses ended before the sun rose and there was enough time left to perform a complete rak’ah. When she becomes pure she has to make up that Fajr prayer, because she had enough time to perform one rak’ah.
But if there is not enough time to perform a rak’ah, such as in the first scenario, if a woman gets her menses a moment after the sun sets or, in the second scenario, she becomes pure a moment before the sun rises, then she does not have to do that prayer, because the Prophet (peace and blessings of Allaah be upon him) said: “Whoever catches up with a rak’ah of prayer has caught up with the prayer.” Agreed upon.
(Source islamqa #70438
So in the given case it is the best for this woman to check a few minutes before fajr whether or not her menses ended, as else she may miss a prayer that was a due on her.
Note that the above statement is based on the Fatwa from islamqa. There might be more lenient opinions in this matter. Furthermore this fatwa seems to consider that purity starts with the end of the menses while we usually say that purity is regained by ghusl.