Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if args.completion_file:
print(os.path.join(os.path.dirname(__file__), 'shell_completion.sh'))
return 0
# Argument-completion for bash and zsh (for test-target completion)
if args.completions:
print(getCompletions(args.targets))
return 0
# Option-completion for bash and zsh
if args.options:
print('\n'.join(sorted(args.store_opt.options)))
return 0
# Add debug logging for stuff that happened before this point here
if config.files_loaded:
debug("Loaded config file(s): {}".format(
', '.join(config.files_loaded)))
# Discover/Load the test suite
if testing:
test_suite = None
else: # pragma: no cover
loader = GreenTestLoader()
test_suite = loader.loadTargets(args.targets,
file_pattern=args.file_pattern)
# We didn't even load 0 tests...
if not test_suite:
debug(
"No test loading attempts succeeded. Created an empty test suite.")
test_suite = GreenTestSuite()
return 0
# Argument-completion for bash and zsh (for test-target completion)
if args.completions:
print(getCompletions(args.targets))
return 0
# Option-completion for bash and zsh
if args.options:
print('\n'.join(sorted(args.store_opt.options)))
return 0
# Add debug logging for stuff that happened before this point here
if config.files_loaded:
debug("Loaded config file(s): {}".format(
', '.join(config.files_loaded)))
# Discover/Load the test suite
if testing:
test_suite = None
else: # pragma: no cover
loader = GreenTestLoader()
test_suite = loader.loadTargets(args.targets,
file_pattern=args.file_pattern)
# We didn't even load 0 tests...
if not test_suite:
debug(
"No test loading attempts succeeded. Created an empty test suite.")
test_suite = GreenTestSuite()
# Actually run the test_suite