I would disagree that some people need to lie to themselves to be happy at all. People who believe delusions are not facing reality. I think that anybody can learn to live without lying to themselves. This is important to me personally because I like to believe as many true things and as few false things as possible.
As for a god being undetectable, if anything manifests in reality in some way, then it would be possible to test those manifestations.
Here's a some food for though: Let's say there are two gods. One is to my left, and the other is to my right. They are both invisible and undetectable. The only difference is that one is real and the other is imaginary. How do you tell which one is real?
Before I answer your question, there is a reason I highlighted those phrases.
From your contrarian style of argument it seems you are an academic. (A cute one at that!)
I've met people like you in this fashion as a (tentative) member of academia. We can "rationalize" away the legitimate opinions and views of those not characteristic of this academic community. The ever increasing unpopularity of firm religious belief seems to have prompted an overlooking of what brings people to religion.
Outside of the middle-class bubble that is academia, rationalization is not enough for the woes of many people. Pie charts do not feed your family. NMR Spectroscopy does not allow you to fix a tormented past. Witty debate does not raise your dead mother. Socratic apology does not keep your parents from beating you.
Yes for some people LIKE YOU, facing the truth all the time may be better. Maybe that's because your truth is easier to swallow/you're good at deep throat (lol, I kid... unless you are.. then yay!). Some people's realities are too much to swallow and they deal with it best by assuring themselves there is a god. That may be all they have. Their god, real or unreal, could be the only thing they perceive as loving them. My privilege as a member of academia has allowed me to meet hordes of people from parts of the world where faith is the only support they can afford.
I say facing reality is overrated. So they (falsely) say that a god or gods cannot within a shadow of a doubt exist. Now what? They are still homeless, uneducated, abused, under-served... except now they don't have anybody they believe loves them unconditionally.
Does this slight (in the scheme of things) distortion of reality perception bring malice to anybody directly? No. Unless their god hates fags or w/e, but that's another issue.
If you are reasonably sane person you probably assume beyond a doubt (subconsciously at least) that you and everybody in your life that you have ever loved are real. All those matrix-y philosophies blew that shit out the water. We can no longer assume that anything we observe with our eyes is truly real with any absolute proof. Absolute proof of anything doesn't even exist. Our universe could be a fabrication. You could be a fabrication. Maybe there isn't even a fabrication... just a semblance of one. If you are sane, I doubt these thoughts race through your head all the time. You assume what is most comfortable and get on with your damn life.
Even now, you probably assume on some level that I am not a psycho killer tracing your IP. Sure you can turn around and say that you do not make that assumption, but I doubt your life is worth posting on some silly porn forum. We all make assumptions based in some kind of faith. A lot of these assumptions are harmless and streamline life.
To answer your contrarian question: You can't tell absolutely. I never said you could. Don't ask me for shit if you want definite proof of a god. I'm with the OP on this one, no definitive proof either way. As long as it is a net good for your world, believe in whichever left or right hand god you want. Or don't believe in either. That's your decision.
A question to you: if you took a person that was perfectly rational and decent save a 100% faith in God, what would a 100% atheist view do for them or anybody around them?
Oh, and you can't bring up the sins of institutional religions in your answer, or a discrimination against the faithless. Atheists discriminate against the faithful all the time, and atheists have done their fair share of shit. Just tell me what shaking his faith itself would do (besides giving him a more "scientific view of reality", unless you can tell me how that would optimize his life.)