summaryrefslogtreecommitdiff
path: root/test/entity_tests.py
diff options
context:
space:
mode:
authorNick Wellnhofer <wellnhofer@aevum.de>2020-01-15 15:08:57 +0100
committerJohn MacFarlane <jgm@berkeley.edu>2020-01-15 07:04:27 -0800
commit6b64a95713fc8a045f8e40949cec0765e0acb9b8 (patch)
treea3569486bc4e8b91ccd392549bba10d45fce59dd /test/entity_tests.py
parent572557dd3ca0cedecba3833111bb04bb5668db43 (diff)
Remove useless __name__ check in test scripts
These checks don't seem to be required and broke pathological_tests.py on Windows where multiprocessing sets __name__ to "__mp_main__".
Diffstat (limited to 'test/entity_tests.py')
-rw-r--r--test/entity_tests.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/test/entity_tests.py b/test/entity_tests.py
index ebaf9f7..27b70e6 100644
--- a/test/entity_tests.py
+++ b/test/entity_tests.py
@@ -19,13 +19,12 @@ def get_entities():
entities.append((entity, utf8))
return entities
-if __name__ == "__main__":
- parser = argparse.ArgumentParser(description='Run cmark tests.')
- parser.add_argument('--program', dest='program', nargs='?', default=None,
- help='program to test')
- parser.add_argument('--library-dir', dest='library_dir', nargs='?',
- default=None, help='directory containing dynamic library')
- args = parser.parse_args(sys.argv[1:])
+parser = argparse.ArgumentParser(description='Run cmark tests.')
+parser.add_argument('--program', dest='program', nargs='?', default=None,
+ help='program to test')
+parser.add_argument('--library-dir', dest='library_dir', nargs='?',
+ default=None, help='directory containing dynamic library')
+args = parser.parse_args(sys.argv[1:])
cmark = CMark(prog=args.program, library_dir=args.library_dir)