fixed test case: dynamic_casts, exception_partial_info, li_std_string, size_t
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9636 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
6ffd26cc1e
commit
e545d7b957
6 changed files with 77 additions and 10 deletions
15
Examples/test-suite/lua/dynamic_cast_runme.lua
Normal file
15
Examples/test-suite/lua/dynamic_cast_runme.lua
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
require("import") -- the import fn
|
||||
import("dynamic_cast") -- import code
|
||||
|
||||
f = dynamic_cast.Foo()
|
||||
b = dynamic_cast.Bar()
|
||||
|
||||
x = f:blah()
|
||||
y = b:blah()
|
||||
|
||||
-- swig_type is a swiglua specific function which gets the swig_type_info's name
|
||||
assert(swig_type(f)==swig_type(x))
|
||||
assert(swig_type(b)==swig_type(y))
|
||||
|
||||
-- the real test: is y a Foo* or a Bar*?
|
||||
assert(dynamic_cast.do_test(y)=="Bar::test")
|
||||
Loading…
Add table
Add a link
Reference in a new issue