aboutsummaryrefslogtreecommitdiff
path: root/unit_tests
diff options
context:
space:
mode:
Diffstat (limited to 'unit_tests')
-rw-r--r--unit_tests/linda_tests.cpp1
-rw-r--r--unit_tests/scripts/lane/tasking_cancelling.lua2
-rw-r--r--unit_tests/scripts/lane/tasking_communications.lua2
3 files changed, 2 insertions, 3 deletions
diff --git a/unit_tests/linda_tests.cpp b/unit_tests/linda_tests.cpp
index 2308737..f2934eb 100644
--- a/unit_tests/linda_tests.cpp
+++ b/unit_tests/linda_tests.cpp
@@ -106,7 +106,6 @@ TEST_CASE("linda.single Keeper")
106 S.requireFailure("lanes.linda():send(0, io.stdin, 'v')"); 106 S.requireFailure("lanes.linda():send(0, io.stdin, 'v')");
107 S.requireFailure("lanes.linda():send(0, lanes.null, 'v')"); 107 S.requireFailure("lanes.linda():send(0, lanes.null, 'v')");
108 S.requireFailure("lanes.linda():send(0, lanes.cancel_error, 'v')"); 108 S.requireFailure("lanes.linda():send(0, lanes.cancel_error, 'v')");
109 S.requireFailure("local l = lanes.linda(); l:send(0, l.batched, 'v')");
110 } 109 }
111 110
112 // ----------------------------------------------------------------------------------------- 111 // -----------------------------------------------------------------------------------------
diff --git a/unit_tests/scripts/lane/tasking_cancelling.lua b/unit_tests/scripts/lane/tasking_cancelling.lua
index 8bee3a6..ea4516e 100644
--- a/unit_tests/scripts/lane/tasking_cancelling.lua
+++ b/unit_tests/scripts/lane/tasking_cancelling.lua
@@ -61,7 +61,7 @@ PRINT "wait_receive_lane is cancelled"
61local wait_receive_batched = function() 61local wait_receive_batched = function()
62 local k, v1, v2 62 local k, v1, v2
63 set_finalizer(function() print("wait_receive_batched", k, v1, v2) end) 63 set_finalizer(function() print("wait_receive_batched", k, v1, v2) end)
64 k, v1, v2 = limited:receive(limited.batched, "dummy", 2) -- infinite timeout, returns only when lane is cancelled 64 k, v1, v2 = limited:receive_batched("dummy", 2) -- infinite timeout, returns only when lane is cancelled
65end 65end
66 66
67local wait_receive_batched_lane = lanes_gen("*", { name = 'auto' }, wait_receive_batched)() 67local wait_receive_batched_lane = lanes_gen("*", { name = 'auto' }, wait_receive_batched)()
diff --git a/unit_tests/scripts/lane/tasking_communications.lua b/unit_tests/scripts/lane/tasking_communications.lua
index 1fd43b0..631d105 100644
--- a/unit_tests/scripts/lane/tasking_communications.lua
+++ b/unit_tests/scripts/lane/tasking_communications.lua
@@ -90,7 +90,7 @@ local b,x,y,z,w = linda:get("<->", 4)
90assert(b == 3 and x == "x" and y == "y" and z == "z" and w == nil) 90assert(b == 3 and x == "x" and y == "y" and z == "z" and w == nil)
91local k, x = linda:receive("<->") 91local k, x = linda:receive("<->")
92assert(k == "<->" and x == "x") 92assert(k == "<->" and x == "x")
93local k,y,z = linda:receive(linda.batched, "<->", 2) 93local k,y,z = linda:receive_batched("<->", 2)
94assert(k == "<->" and y == "y" and z == "z") 94assert(k == "<->" and y == "y" and z == "z")
95linda:set("<->") 95linda:set("<->")
96local b,x,y,z,w = linda:get("<->", 4) 96local b,x,y,z,w = linda:get("<->", 4)