File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 2828except ImportError :
2929 xxsubtype = None
3030
31+ try :
32+ import xxlimited
33+ except ImportError :
34+ xxlimited = None
35+
3136
3237class OperatorsTest (unittest .TestCase ):
3338
@@ -1803,6 +1808,8 @@ class SubSpam(spam.spamlist): pass
18031808 spam_cm .__get__ (None , list )
18041809 self .assertEqual (str (cm .exception ), expected_errmsg )
18051810
1811+ @support .impl_detail ("the module 'xxlimited' is internal" )
1812+ @unittest .skipIf (xxlimited is None , "requires xxlimited module" )
18061813 def test_method_get_meth_method_invalid_type (self ):
18071814 # gh-146615: method_get() for METH_METHOD descriptors used to pass
18081815 # Py_TYPE(type)->tp_name as the %V fallback instead of the separate
@@ -1812,9 +1819,6 @@ def test_method_get_meth_method_invalid_type(self):
18121819 #
18131820 # METH_METHOD|METH_FASTCALL|METH_KEYWORDS is the only flag combination
18141821 # that enters the affected branch in method_get().
1815-
1816- import xxlimited
1817-
18181822 xxo = xxlimited .Xxo ()
18191823 descr = xxlimited .Xxo .demo
18201824
You can’t perform that action at this time.
0 commit comments