|
|
|
@ -61,7 +61,7 @@ function test_call_sync()
|
|
|
|
bc1:finalize()
|
|
|
|
bc1:finalize()
|
|
|
|
|
|
|
|
|
|
|
|
-- Test locally
|
|
|
|
-- Test locally
|
|
|
|
assert_nil(bc1:call("sync1", 20, 12), "call not nil")
|
|
|
|
assert_true(bc1:call("sync1", 20, 12), "call not true")
|
|
|
|
local ret, val = bc1:call_sync("sync1", 30, 12)
|
|
|
|
local ret, val = bc1:call_sync("sync1", 30, 12)
|
|
|
|
assert_equal(40, ret, "local sync not correct")
|
|
|
|
assert_equal(40, ret, "local sync not correct")
|
|
|
|
assert_equal("hello", val, "local sync not multiple")
|
|
|
|
assert_equal("hello", val, "local sync not multiple")
|
|
|
|
@ -69,7 +69,7 @@ function test_call_sync()
|
|
|
|
|
|
|
|
|
|
|
|
-- Test remote
|
|
|
|
-- Test remote
|
|
|
|
local bc2 = BaseControl:new()
|
|
|
|
local bc2 = BaseControl:new()
|
|
|
|
assert_nil(bc2:call("sync1", 20, 12), "call not nil")
|
|
|
|
assert_true(bc2:call("sync1", 20, 12), "call not true")
|
|
|
|
local ret, val = bc2:call_sync("sync1", 30, 12)
|
|
|
|
local ret, val = bc2:call_sync("sync1", 30, 12)
|
|
|
|
assert_equal(40, ret, "local sync not correct")
|
|
|
|
assert_equal(40, ret, "local sync not correct")
|
|
|
|
assert_equal("hello", val, "local sync not multiple")
|
|
|
|
assert_equal("hello", val, "local sync not multiple")
|
|
|
|
|