From bb419057f8dab442b047a8635e44f42c03c17dff Mon Sep 17 00:00:00 2001 From: Mitesh Ashar Date: Tue, 13 Dec 2022 15:13:57 +0530 Subject: [PATCH] Rename unified_diff_output to fail_with_diff --- tests/conftest.py | 2 +- tests/unit/utils/markdown/test_markdown.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index 5c5b37292..369134233 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1692,7 +1692,7 @@ def new_proposal(models, db_session, new_user, new_project) -> funnel_models.Pro @pytest.fixture() -def unified_diff_output(): +def fail_with_diff(): def func(left, right): if left != right: difference = unified_diff(left.split('\n'), right.split('\n')) diff --git a/tests/unit/utils/markdown/test_markdown.py b/tests/unit/utils/markdown/test_markdown.py index 2fbb8df9a..e55c52183 100644 --- a/tests/unit/utils/markdown/test_markdown.py +++ b/tests/unit/utils/markdown/test_markdown.py @@ -25,7 +25,7 @@ def test_markdown_blank() -> None: # def test_markdown_cases( -# md_testname: str, md_configname: str,markdown_test_registry, unified_diff_output) -> None: +# md_testname: str, md_configname: str,markdown_test_registry, fail_with_diff # ) -> None: def test_markdown_cases( md_testname: str, md_configname: str, markdown_test_registry @@ -38,7 +38,7 @@ def test_markdown_cases( assert case.expected_output == case.output # Debug function - # unified_diff_output(case.expected_output, case.output) + # fail_with_diff(case.expected_output, case.output) @pytest.mark.update_markdown_data()