mirror of https://github.com/python/cpython
gh-107461 ctypes: Add a testcase for nested `_as_parameter_` lookup (GH-107462)
This commit is contained in:
parent
59ae215387
commit
0bf42dae7e
|
@ -221,5 +221,16 @@ class AsParamPropertyWrapperTestCase(BasicWrapTestCase):
|
||||||
wrap = AsParamPropertyWrapper
|
wrap = AsParamPropertyWrapper
|
||||||
|
|
||||||
|
|
||||||
|
class AsParamNestedWrapperTestCase(BasicWrapTestCase):
|
||||||
|
"""Test that _as_parameter_ is evaluated recursively.
|
||||||
|
|
||||||
|
The _as_parameter_ attribute can be another object which
|
||||||
|
defines its own _as_parameter_ attribute.
|
||||||
|
"""
|
||||||
|
|
||||||
|
def wrap(self, param):
|
||||||
|
return AsParamWrapper(AsParamWrapper(AsParamWrapper(param)))
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
|
Loading…
Reference in New Issue