Mishkat al-Masabih 11
وَعَنْ أَبِي مُوسَى الْأَشْعَرِيِّ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: ثَلَاثَةٌ لَهُمْ أَجْرَانِ: رَجُلٌ مِنْ أَهْلِ الْكِتَابِ آمَنَ بِنَبِيِّهِ وَآمَنَ بِمُحَمَّدٍ وَالْعَبْدُ الْمَمْلُوكُ إِذَا أَدَّى حَقَّ اللَّهِ وَحَقَّ مَوَالِيهِ وَرَجُلٌ كَانَتْ عِنْدَهُ أَمَةٌ يَطَؤُهَا فَأَدَّبَهَا فَأَحْسَنَ تَأْدِيبَهَا وَعَلَّمَهَا فَأَحْسَنَ تَعْلِيمِهَا ثُمَّ أَعْتَقَهَا فَتَزَوَّجَهَا فَلَهُ أَجْرَانِ
From Abu Musa al-Ashʿari, who said: The Messenger of Allah ﷺ said: "Three [people] will have two rewards: a man of the People of the Book who believed in his prophet and believed in Muhammad; the owned slave when he fulfils the right of Allah and the right of his masters; and a man who had a slave-woman with whom he had relations, and he disciplined her and disciplined her well, taught her and taught her well, then freed her and married her; he will have two rewards."