The Messenger of Allah ﷺ would only test them with the verse in which Allah said, "When the believing women come to you pledging allegiance to you" [Mumtahanah 60:12], the verse.Muamar said, Ibn Tawus reported to me from his father, who said, "The hand of the Messenger of Allah ﷺ never touched the hand of any woman except a woman whom he owned in marriage."He said, this is a hasan sahih hadith.
حدثنا عبد بن حميد حدثنا عبد الرزاق عن معمر عن الزهري عن عروة
ما كان رسول الله ﷺ يمتحن إلا بالآية التي قال الله {إذا جاءك المؤمنات يبايعنك} الآية قال معمر فأخبرني ابن طاووس عن أبيه قال ما مست يد رسول الله ﷺ يد امرأة إلا امرأة يملكها قال هذا حديث حسن صحيح
Agreed upon (by Bukhari and Muslim). Bukhari related it in the Book of Judgments, Chapter on the Pledge of Allegiance of Women, no. 7214, from the hadith of Abdul-Razzaq, and Muslim, no. 1866, from the hadith of Zuhri, with the same wording.