File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 1
1
import os
2
+ import sys
2
3
import unittest
3
4
import warnings
4
5
from io import StringIO
@@ -180,7 +181,9 @@ class SkippedTestsSubclass(SkippedTests):
180
181
except unittest .SkipTest :
181
182
self .fail ("SkipTest should not be raised here." )
182
183
result = unittest .TextTestRunner (stream = StringIO ()).run (test_suite )
183
- self .assertEqual (result .testsRun , 3 )
184
+ # PY312: Python 3.12.1+ no longer includes skipped tests in the number
185
+ # of running tests.
186
+ self .assertEqual (result .testsRun , 1 if sys .version_info >= (3 , 12 , 1 ) else 3 )
184
187
self .assertEqual (len (result .skipped ), 2 )
185
188
self .assertEqual (result .skipped [0 ][1 ], "Database has feature(s) __class__" )
186
189
self .assertEqual (result .skipped [1 ][1 ], "Database has feature(s) __class__" )
You can’t perform that action at this time.
0 commit comments