Because such a test could be used against Christians too.
Via Washington Post:
Responding to Ben Carson’s opposition to a Muslim president, Sen. Ted Cruz (R-Tex.) said it would be unconstitutional to prohibit someone from being president because of their religion. But he also said the Obama administration’s plan to allow tens of thousands of Muslim refugees from Syria into the U.S. is “crazy.”
Carson, one of Cruz’s opponents in the crowded GOP presidential primary field, has said he “would not advocate putting a Muslim in charge of this nation;” Cruz said that the Constitution does not allow a specific religion to be a qualification for the presidency.