Minor fix of quarantine naming
This commit is contained in:
@@ -274,8 +274,8 @@ class DatabaseBroker(object):
|
|||||||
partition_path = os.path.dirname(prefix_path)
|
partition_path = os.path.dirname(prefix_path)
|
||||||
dbs_path = os.path.dirname(partition_path)
|
dbs_path = os.path.dirname(partition_path)
|
||||||
device_path = os.path.dirname(dbs_path)
|
device_path = os.path.dirname(dbs_path)
|
||||||
quar_path = os.path.join(device_path, 'quarantined', self.db_type,
|
quar_path = os.path.join(device_path, 'quarantined',
|
||||||
os.path.basename(self.db_dir))
|
self.db_type + 's', os.path.basename(self.db_dir))
|
||||||
try:
|
try:
|
||||||
renamer(self.db_dir, quar_path)
|
renamer(self.db_dir, quar_path)
|
||||||
except OSError, e:
|
except OSError, e:
|
||||||
|
@@ -206,9 +206,9 @@ class TestDatabaseBroker(unittest.TestCase):
|
|||||||
qpath = os.path.dirname(os.path.dirname(os.path.dirname(
|
qpath = os.path.dirname(os.path.dirname(os.path.dirname(
|
||||||
os.path.dirname(self.testdir))))
|
os.path.dirname(self.testdir))))
|
||||||
if qpath:
|
if qpath:
|
||||||
qpath += '/quarantined/test/db'
|
qpath += '/quarantined/tests/db'
|
||||||
else:
|
else:
|
||||||
qpath = 'quarantined/test/db'
|
qpath = 'quarantined/tests/db'
|
||||||
# Test malformed database
|
# Test malformed database
|
||||||
copy(os.path.join(os.path.dirname(__file__),
|
copy(os.path.join(os.path.dirname(__file__),
|
||||||
'malformed_example.db'),
|
'malformed_example.db'),
|
||||||
|
Reference in New Issue
Block a user