Skip to content

Commit

Permalink
Allow for changes to archiver invocation
Browse files Browse the repository at this point in the history
  • Loading branch information
sebbASF committed Oct 7, 2021
1 parent fe9befa commit 780e31d
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions test/generatortest.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@
GENS=generators.generator_names()

archie = archiver.Archiver(parse_html = parseHTML)
fake_args = namedtuple('fakeargs', ['verbose', 'ibody'])(False, None)


for arg in sys.argv[1:]:
Expand All @@ -68,9 +67,9 @@
break
if 'gen' in script:
print("Generator %s" % script['gen'])
archiver.archiver_generator = script['gen']
archie.generator = script['gen']
message = next(messages)
json, contents, _msgdata, _irt = archie.compute_updates(fake_args, list_override, private, message)
json, contents, _msgdata, _irt = archie.compute_updates(list_override, private, message)
error = 0
for key in script:
if key == 'gen':
Expand All @@ -89,8 +88,8 @@
for message in messages:
print(message.get_from())
for gen in GENS:
archiver.archiver_generator = gen
json, contents, _msgdata, _irt = archie.compute_updates(fake_args, list_override, private, message)
archie.generator = gen
json, contents, _msgdata, _irt = archie.compute_updates(list_override, private, message)
print("%15s: %s" % (gen,json['mid']))
elif arg.endswith('.eml'): # a single email
for gen in GENS:
Expand Down

0 comments on commit 780e31d

Please sign in to comment.