Move Redis code into fakeldap, since it's the only thing that still uses it.
Adjust auth unittests to skip fakeldap tests if Redis isn't around. Adjust auth unittests to actually run the fakeldap tests if Redis /is/ around.
This commit is contained in:
@@ -45,7 +45,6 @@ import sys
|
||||
|
||||
from twisted.scripts import trial as trial_script
|
||||
|
||||
from nova import datastore
|
||||
from nova import flags
|
||||
from nova import twistd
|
||||
|
||||
@@ -86,12 +85,6 @@ if __name__ == '__main__':
|
||||
# TODO(termie): these should make a call instead of doing work on import
|
||||
if FLAGS.fake_tests:
|
||||
from nova.tests.fake_flags import *
|
||||
# use db 8 for fake tests
|
||||
FLAGS.redis_db = 8
|
||||
if FLAGS.flush_db:
|
||||
logging.info("Flushing redis datastore")
|
||||
r = datastore.Redis.instance()
|
||||
r.flushdb()
|
||||
else:
|
||||
from nova.tests.real_flags import *
|
||||
|
||||
|
||||
Reference in New Issue
Block a user