test the SUT

This commit is contained in:
Jean-Paul Calderone 2021-01-10 20:16:25 -05:00
parent 360b20a981
commit 28435d65c1

View File

@ -101,10 +101,12 @@ class GetArgvTests(SyncTestCase):
# file I/O is relatively simple and well-understood. # file I/O is relatively simple and well-understood.
f.write(dedent( f.write(dedent(
""" """
import sys from allmydata.windows.fixups import (
get_argv,
)
import json import json
with open({!r}, "wt") as f: with open({!r}, "wt") as f:
f.write(json.dumps(sys.argv)) f.write(json.dumps(get_argv()))
""".format(saved_argv_path.path)), """.format(saved_argv_path.path)),
) )
# Python 2.7 doesn't have good options for launching a process with # Python 2.7 doesn't have good options for launching a process with