Commit 1d0f6100 authored by Adam Blank's avatar Adam Blank
Browse files

Update test_helpers.py

parent 4a7bcfcd
No related merge requests found
Pipeline #117266 failed with stage
in 0 seconds
Showing with 10 additions and 3 deletions
+10 -3
...@@ -27,10 +27,17 @@ def myprint(*args, **kwargs): ...@@ -27,10 +27,17 @@ def myprint(*args, **kwargs):
output += " ".join(str(arg) for arg in args) + "\n" output += " ".join(str(arg) for arg in args) + "\n"
class OutOfInputError(Exception):
pass
def myinput(prompt): def myinput(prompt):
global input_index try:
response = input_list[input_index] global input_index
input_index += 1 response = input_list[input_index]
input_index += 1
except IndexError:
raise OutOfInputError
return response return response
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment