def test_not_match(file_exists, script, output, exists): file_exists.return_value = exists assert not match(Command(script, output))
def test_match(script, result): output = get_output("source") assert match(Command(script, output)) assert get_new_command(Command(script, output)) == result
def test_not_match(file_exists, script, stderr, exists): file_exists.return_value = exists assert not match(Command(script, stderr=stderr))
def test_match(script, result): stderr = get_stderr('source') assert match(Command(script, stderr=stderr)) assert get_new_command(Command(script, stderr=stderr)) == result
def test_match(script): stderr = get_stderr('source') assert match(Command(script, stderr=stderr))
def test_match(script, result): output = get_output('source') assert match(Command(script, output)) assert get_new_command(Command(script, output)) == result