vrts: fix performance testing

This commit is contained in:
bnnm 2023-11-26 20:59:22 +01:00
parent e8643c333c
commit 7c3b95e8b5

View File

@ -409,7 +409,7 @@ class VrtsFiles:
# same file N times
if self._args.performance and self._args.performance_repeat:
for i in range(self._args.performance_repeat):
for _ in range(self._args.performance_repeat):
self.filenames.append(file)
@ -541,7 +541,7 @@ class VrtsApp:
flag_looping = '-i'
# pases all files at once, as it's faster than 1 by 1 (that has to init program every time)
if self._performance_new:
if self._args.performance_new:
self._p.info("testing new performance")
ts_st = time.time()
@ -551,7 +551,7 @@ class VrtsApp:
ts_ed = time.time()
self._p.info("done: elapsed %ss" % (ts_ed - ts_st))
if self._performance_old:
if self._args.performance_old:
self._p.info("testing old performance")
ts_st = time.time()
@ -559,10 +559,10 @@ class VrtsApp:
res = self._prc.call(args)
ts_ed = time.time()
self._p.info("done: elapsed %ss (%s)" % (ts_ed - ts_st))
self._p.info("done: elapsed %ss" % (ts_ed - ts_st))
#if self._performance_both:
# ...
# handled above
# returns max fuzzy count, except for non-fuzzable files (that use int math)