Author: humbedooh
Date: Tue Dec 8 18:26:14 2015
New Revision: 1718663
URL: http://svn.apache.org/viewvc?rev=1718663&view=rev
Log:
Detect if this is an actual CGI run or if it's a unit test with no database
connectivity.
Modified:
steve/trunk/pysteve/lib/constants.py
Modified: steve/trunk/pysteve/lib/constants.py
URL:
http://svn.apache.org/viewvc/steve/trunk/pysteve/lib/constants.py?rev=1718663&r1=1718662&r2=1718663&view=diff
==============================================================================
--- steve/trunk/pysteve/lib/constants.py (original)
+++ steve/trunk/pysteve/lib/constants.py Tue Dec 8 18:26:14 2015
@@ -55,6 +55,8 @@ def initBackend(config):
# Set up DB backend
backend = None
+ if config.has_option("database", "disabled") and config.get("database",
"disabled") == "true":
+ return
dbtype = config.get("database", "dbsys")
for b in DB_TYPES:
if b.get('id') == dbtype: