added testcase pointer_reference
This commit is contained in:
parent
c0026d036a
commit
63821f1bb5
1 changed files with 24 additions and 0 deletions
24
Examples/test-suite/r/pointer_reference_runme.R
Normal file
24
Examples/test-suite/r/pointer_reference_runme.R
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
clargs <- commandArgs(trailing=TRUE)
|
||||
source(file.path(clargs[1], "unittest.R"))
|
||||
#source("unittest.R")
|
||||
|
||||
dyn.load(paste("pointer_reference", .Platform$dynlib.ext, sep=""))
|
||||
source("pointer_reference.R")
|
||||
cacheMetaData(1)
|
||||
|
||||
|
||||
s = Struct_value_get(Struct_pInstance_get())
|
||||
unittest(s, 10)
|
||||
|
||||
ss = Struct(20)
|
||||
Struct_pInstance_set(ss)
|
||||
s = Struct_value_get(Struct_pInstance_get())
|
||||
unittest(s, 20)
|
||||
|
||||
s = overloading(1)
|
||||
unittest(s, 111)
|
||||
|
||||
s = overloading(ss)
|
||||
unittest(s, 222)
|
||||
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue