Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:20633Abū Ḥāzim al-ʿAbdawī al-Ḥāfiẓ > Abū al-Faḍl b. Khimayrawayh > Aḥmad b. Najdah > Saʿīd b. Manṣūr > Hushaym > Mughīrah > Ibrāhīm And Yūnus > al-Ḥasan And Muḥammad b. Sālim

[Machine] About Ash-Sha'bi, they used to say concerning the testimony of a young boy that if he testified before reaching maturity, then later he reached maturity, the testimony is valid. And the same applies to a Christian or a Jew if they testified while they were in a state of disbelief, then later they embraced Islam. And for a slave, if they testified and then were freed, their testimony is valid. Then they would affirm their testimony that their testimony is valid.  

البيهقي:٢٠٦٣٣وَأَخْبَرَنَا أَبُو حَازِمٍ الْعَبْدَوِيُّ الْحَافِظُ أنبأ أَبُو الْفَضْلِ بْنُ خِمَيْرَوَيْهِ ثنا أَحْمَدُ بْنُ نَجْدَةَ ثنا سَعِيدُ بْنُ مَنْصُورٍ ثنا هُشَيْمٌ أنبأ مُغِيرَةُ عَنْ إِبْرَاهِيمَ وَيُونُسَ عَنِ الْحَسَنِ وَمُحَمَّدِ بْنِ سَالِمٍ

عَنِ الشَّعْبِيِّ أَنَّهُمْ كَانُوا يَقُولُونَ فِي شَهَادَةِ الْغُلَامِ إِذَا شَهِدَ قَبْلَ أَنْ يَبْلُغَ ثُمَّ قَامَ بِهَا إِذَا بَلَغَ وَالنَّصْرَانِيِّ وَالْيَهُودِيِّ إِذَا شَهِدَا فِي حَالِ شِرْكٍ ثُمَّ أَسْلَمَا وَالْعَبْدِ إِذَا شَهِدَ ثُمَّ أُعْتِقَ ثُمَّ قَامُوا بِشَهَادَتِهِمْ أَنَّ شَهَادَتَهُمْ جَائِزَةٌ