[OCaml] Fix the wrapmacro test
Add a typecheck typemap for size_t and const size_t &. Add the const qualifier to the typemaps for primitive reference types. Add multiple runtime tests.
This commit is contained in:
parent
6522afe90a
commit
10d62aecd5
10 changed files with 58 additions and 10 deletions
15
Examples/test-suite/ocaml/global_vars_runme.ml
Normal file
15
Examples/test-suite/ocaml/global_vars_runme.ml
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
open Swig
|
||||
open Global_vars
|
||||
|
||||
_init '()
|
||||
|
||||
let _ =
|
||||
assert (_b '() as string = "string b");
|
||||
assert (_b '("a string value") as string = "a string value");
|
||||
assert (_b '() as string = "a string value");
|
||||
assert (_x '() as int = 1234);
|
||||
assert (_x '(9876) as int = 9876);
|
||||
assert (_x '() as int = 9876);
|
||||
assert (_Hi '() as int = 0);
|
||||
assert (_Hola '() as int = 1);
|
||||
;;
|
||||
Loading…
Add table
Add a link
Reference in a new issue