add smart_pointer +members test
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6809 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
9b963f9763
commit
6923d5346c
3 changed files with 56 additions and 0 deletions
19
Examples/test-suite/python/smart_pointer_member_runme.py
Normal file
19
Examples/test-suite/python/smart_pointer_member_runme.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
from smart_pointer_member import *
|
||||
|
||||
f = Foo()
|
||||
f.y = 1
|
||||
|
||||
if f.y != 1:
|
||||
raise RuntimeError
|
||||
|
||||
b = Bar(f)
|
||||
b.y = 2
|
||||
|
||||
if f.y != 2:
|
||||
raise RuntimeError
|
||||
|
||||
if b.x != f.x:
|
||||
raise RuntimeError
|
||||
|
||||
if b.z != f.z:
|
||||
raise RuntimeError
|
||||
Loading…
Add table
Add a link
Reference in a new issue