-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Smoke Test Loop Script #2038
Smoke Test Loop Script #2038
Conversation
tests_smoke/smoke_loop.py
Outdated
init() | ||
|
||
|
||
while True: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would put both the init() and this part under the main function, that would be the pythonic way to call this:
def main():
print("Hello World!")
if __name__ == "__main__":
main()
tests_smoke/smoke_loop.py
Outdated
|
||
result = None | ||
seconds = None | ||
startTime = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you don't need to initiatize both startTime and endTime as you are reinitializing underneath
global maxRuns | ||
|
||
parser = ArgumentParser() | ||
parser.add_argument("-m", "--max-runs", dest="maxruns", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you could add this documentation in either the Makefile and on top of this script so folks have an example of how to run it
Summary | Résumé
Here's a quick script that will run the smoke tests in a loop for a given number of times (or indefinitely)
Test instructions | Instructions pour tester la modification
make smoke-loop -m 2