I would hope that any deity which inspired a religion worthy of pledging oneself to would be at least as wise as the most free society on the earth, in how the situation is actually dealt with.
Just denying would get you no punishment I assume, treason can get you the death penalty so I guess the penalty in betrayal depends on the degree.
Still --- our Faith and our nation were built up more by the martyrs and heroes than by the cowards.
It's like watching Braveheart or The Patriot --- how much could we ourselves endure for our beliefs? As much as we might laugh at the French, it's all easy when it's from a distance. Ten years ago it certainly didn't seem like such a real possibility.