diff --git a/CHANGES.rst b/CHANGES.rst index ba6ee45b2..f1aae5de8 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -4,6 +4,13 @@ Changes Unreleased ---------- + +3.9.0 (2025-01-26) +------------------ + +- Removed the ``simple_history_admin_list.display_list()`` template tag that was + deprecated in version 3.6.0 (gh-1444) + 3.8.0 (2025-01-23) ------------------ @@ -19,6 +26,8 @@ Unreleased - Fixed issue with history button not working when viewing historical entries in the admin (gh-527) - Added support for Django 5.2 (gh-1441) +- ``simple_history_admin_list.display_list()`` *was planned to be removed in this + release, but it was overlooked, and will instead be removed in 3.9.0* 3.7.0 (2024-05-29) ------------------ diff --git a/simple_history/templatetags/simple_history_admin_list.py b/simple_history/templatetags/simple_history_admin_list.py deleted file mode 100644 index b6546784c..000000000 --- a/simple_history/templatetags/simple_history_admin_list.py +++ /dev/null @@ -1,15 +0,0 @@ -import warnings - -from django import template - -register = template.Library() - - -@register.inclusion_tag("simple_history/object_history_list.html", takes_context=True) -def display_list(context): - warnings.warn( - "'include' the context variable 'object_history_list_template' instead." - " This will be removed in version 3.8.", - DeprecationWarning, - ) - return context diff --git a/simple_history/tests/tests/test_deprecation.py b/simple_history/tests/tests/test_deprecation.py index 7c8ca9990..0bfb5e452 100644 --- a/simple_history/tests/tests/test_deprecation.py +++ b/simple_history/tests/tests/test_deprecation.py @@ -1,13 +1,10 @@ import unittest -from simple_history import __version__ -from simple_history.templatetags.simple_history_admin_list import display_list - class DeprecationWarningTest(unittest.TestCase): - def test__display_list__warns_deprecation_and_is_yet_to_be_removed(self): - with self.assertWarns(DeprecationWarning): - display_list({}) - # DEV: `display_list()` (and the file `simple_history_admin_list.py`) should be - # removed when 3.8 is released - self.assertLess(__version__, "3.8") + """Tests that check whether ``DeprecationWarning`` is raised for certain features, + and that compare ``simple_history.__version__`` against the version the features + will be removed in. + + If this class is empty, it normally means that nothing is currently deprecated. + """