Change to logout to $stdout

* Fits in with how we already check stdout in specs
* Easier to mock without errors about re-declaring a constant
Change logic around detection of filtering logs

Before logic was dependant on environment variables being strings, this is much better :+1:
Add spec to for DEBUG=$value CLI setting
Rename spec from redact to debug
Merge pull request #140 from pearkes/fix_debug_logging

Fix API key redacting for DEBUG=2