1788
North Carolina debates whether a Muslim could be president
At the state's ratifying convention, delegates debate Article VI's ban on religious tests. James Iredell, soon a Supreme Court justice, argues that excluding anyone, including 'Mahometans,' would 'take away that principle of religious freedom which we ourselves so warmly contend for.'
Delegate William Lancaster conceded the logic: someday a 'Mahometan' might be president. The question the convention argued in the abstract was answered by real oaths two centuries later: Congress in 2006, and the New York mayoralty in 2026.
Source
The Founders' Constitution (Univ. of Chicago), NC ratifying convention debate