Skip to content
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

Closed
wants to merge 5 commits into from
Closed

Smoke Test Loop Script #2038

wants to merge 5 commits into from

Conversation

ben851
Copy link
Contributor

@ben851 ben851 commented Nov 24, 2023

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

tests_smoke/smoke_loop.py Fixed Show fixed Hide fixed
init()


while True:
Copy link
Collaborator

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()


result = None
seconds = None
startTime = None
Copy link
Collaborator

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",
Copy link
Collaborator

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

@ben851 ben851 closed this Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants