From 85cd1c5e0b95a75385e68972ceef3329edb7b7f0 Mon Sep 17 00:00:00 2001
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
Date: Mon, 30 Oct 2023 10:38:27 -0400
Subject: [PATCH 1/2] Fix tests to handle Python 3.13 stripping indents from
 docstrings

https://docs.python.org/3.13/whatsnew/3.13.html#other-language-changes

https://github.com/python/cpython/issues/81283
---
 parameterized/test.py | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/parameterized/test.py b/parameterized/test.py
index 6419171..6d11e32 100644
--- a/parameterized/test.py
+++ b/parameterized/test.py
@@ -385,6 +385,8 @@ def _assert_docstring(self, expected_docstring, rstrip=False):
         actual_docstring = test_method.__doc__
         if rstrip:
             actual_docstring = actual_docstring.rstrip()
+        if sys.version_info[:2] >= (3, 13):
+            expected_docstring = inspect.cleandoc(expected_docstring)
         assert_equal(actual_docstring, expected_docstring)
 
     @parameterized.expand([param("foo")],