Skip to content

Commit

Permalink
Merge pull request #14 from plone/py-3.13-unittest
Browse files Browse the repository at this point in the history
Fix removed `unittest.makeSuite` in py 3.13
  • Loading branch information
petschki authored Nov 29, 2024
2 parents 0acedea + dd64846 commit b68bd2b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 2 additions & 0 deletions news/14.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Fix removed `unittest.makeSuite` in python 3.13.
[petschki]
9 changes: 5 additions & 4 deletions src/collective/monkeypatcher/tests/test_monkeypatcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ def test_monkeyPatchEvent(self):


def test_suite():
from unittest import TestSuite, makeSuite
suite = TestSuite()
suite.addTest(makeSuite(TestMonkeyPatcher))
return suite
import unittest

return unittest.TestSuite((
unittest.defaultTestLoader.loadTestsFromTestCase(TestMonkeyPatcher),
))

0 comments on commit b68bd2b

Please sign in to comment.