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
16
Examples/test-suite/lua/li_std_except_runme.lua
Normal file
16
Examples/test-suite/lua/li_std_except_runme.lua
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
require("import") -- the import fn
|
||||
import("li_std_except") -- import code
|
||||
|
||||
test = li_std_except.Test()
|
||||
-- under lua, all the std::exceptions are just turned to strings, so we are only checking that is fails
|
||||
assert(pcall(function() test:throw_bad_exception() end)==false)
|
||||
assert(pcall(function() test:throw_domain_error() end)==false)
|
||||
assert(pcall(function() test:throw_exception() end)==false)
|
||||
assert(pcall(function() test:throw_invalid_argument() end)==false)
|
||||
assert(pcall(function() test:throw_length_error() end)==false)
|
||||
assert(pcall(function() test:throw_logic_error() end)==false)
|
||||
assert(pcall(function() test:throw_out_of_range() end)==false)
|
||||
assert(pcall(function() test:throw_overflow_error() end)==false)
|
||||
assert(pcall(function() test:throw_range_error() end)==false)
|
||||
assert(pcall(function() test:throw_runtime_error() end)==false)
|
||||
assert(pcall(function() test:throw_underflow_error() end)==false)
|
||||
Loading…
Add table
Add a link
Reference in a new issue