Atheists (and other non-believers) know more about religion than your average American Christian. Some articles do a better job of discussing the reasons for this than others.
One correlating factor is that the irreligious tend to be better educated than the religious, and as many of the stories pointed out, level of education correlated highly with performance on the test. The correlation with lack of belief should tell you something right there. However, if you put that together with these other factors, as reported in another article (I think it was in the LA Times) that education alone was not enough to explain the higher scores of non-believers, and indeed they still scored higher than believers with the same level of education.
Another correlating factor is that in a country that has a predominantly Christian population, it was the religious that are most out of the mainstream that performed the best on the test (atheists and agnostics were followed by Muslims and other non-Christians, followed by Mormons). In such an environment, one is naturally exposed to a lot of Christian doctrine, but is also more aware of the practices of their own faith (or lack of it), and are also highly motivated to be aware of separation of church and state issues discussed in the survey.
A third factor that is related to this is that most atheists in America grow up in Christian households. Atheists don't leave religion because of a lack of knowledge (indeed, this survey confirms quite the opposite, that lack of knowledge suggests you are more willing to stay); rather, atheists leave religion because of a crisis of faith. Such crises often prompt a good deal of soul-searching, investigation into the tenants of one's religious heritage and that of other faiths prior to abandoning religion altogether. This kind of investigation of other religions is not something that those who never question their faiths ever engage in.
Save this link for the next time some apologist tells you that you don't know enough about religion. I'm nearly through the Bible, I've read the Book of Mormon, if only I can find an audiobook of the Koran... though, the Tibetan Book of the Dead might be easier to track down. :) Still, as those who have left the religion well know, there is a lot about most religions that you won't find in their holy books. These should never be considered the be-all-and-end-all of any investigation into religion. The Stanford Encyclopedia of Philosophy is a better resource.