add flush output steps to behave, update delete flag tests

This commit is contained in:
Jonathan Wren 2020-09-24 20:41:08 -07:00
parent bb5f7a830a
commit 242467da37
No known key found for this signature in database
GPG key ID: 43D5FF8722E7F68A
2 changed files with 56 additions and 17 deletions

View file

@ -355,6 +355,26 @@ def no_error(context):
assert context.exit_status == 0, context.exit_status
@then("we flush the output")
def flush_stdout(context):
context.stdout_capture.truncate(0)
context.stdout_capture.seek(0)
@then("we flush the error output")
def flush_stderr(context):
context.stderr_capture.truncate(0)
context.stderr_capture.seek(0)
@then("we flush all the output")
def flush_stderr(context):
context.execute_steps('''
Then we flush the output
Then we flush the error output
''')
@then("the output should be")
@then("the output should be empty")
@then('the output should be "{text}"')