mirror of https://github.com/borgbackup/borg.git
fix tests: they expect check to spew output
our default verbosity shows only warnings, we'd have to tweak tests to be verbose for this to work
This reverts commit 27be46a5ba
.
This commit is contained in:
parent
3f68399463
commit
efa88ef6c6
|
@ -677,7 +677,7 @@ class ArchiveChecker:
|
||||||
def report_progress(self, msg, error=False):
|
def report_progress(self, msg, error=False):
|
||||||
if error:
|
if error:
|
||||||
self.error_found = True
|
self.error_found = True
|
||||||
logger.log(logging.ERROR if error else logging.INFO, msg)
|
logger.log(logging.ERROR if error else logging.WARNING, msg)
|
||||||
|
|
||||||
def identify_key(self, repository):
|
def identify_key(self, repository):
|
||||||
cdata = repository.get(next(self.chunks.iteritems())[0])
|
cdata = repository.get(next(self.chunks.iteritems())[0])
|
||||||
|
@ -804,7 +804,7 @@ class ArchiveChecker:
|
||||||
num_archives = 1
|
num_archives = 1
|
||||||
end = 1
|
end = 1
|
||||||
for i, (name, info) in enumerate(archive_items[:end]):
|
for i, (name, info) in enumerate(archive_items[:end]):
|
||||||
self.report_progress('Analyzing archive {} ({}/{})'.format(name, num_archives - i, num_archives))
|
logger.info('Analyzing archive {} ({}/{})'.format(name, num_archives - i, num_archives))
|
||||||
archive_id = info[b'id']
|
archive_id = info[b'id']
|
||||||
if archive_id not in self.chunks:
|
if archive_id not in self.chunks:
|
||||||
self.report_progress('Archive metadata block is missing', error=True)
|
self.report_progress('Archive metadata block is missing', error=True)
|
||||||
|
|
|
@ -84,7 +84,7 @@ Type "Yes I am sure" if you understand this and want to continue.\n""")
|
||||||
if input('Do you want to continue? ') == 'Yes I am sure':
|
if input('Do you want to continue? ') == 'Yes I am sure':
|
||||||
break
|
break
|
||||||
if not args.archives_only:
|
if not args.archives_only:
|
||||||
logger.info('Starting repository check...')
|
logger.warning('Starting repository check...')
|
||||||
if repository.check(repair=args.repair):
|
if repository.check(repair=args.repair):
|
||||||
logger.info('Repository check complete, no problems found.')
|
logger.info('Repository check complete, no problems found.')
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue