def test_check_for_uncommitted_files_raises_error(execute_shell_mock): execute_shell_mock.return_value = 'asdf' try: publish.check_for_uncommitted_files() assert False, 'expecting ValueError' except ValueError as e: assert 'uncommitted' in '\n'.join(e.args)
def test_check_for_uncommitted_files(execute_shell_mock): execute_shell_mock.return_value = 'nothing to commit' publish.check_for_uncommitted_files()