diff options
| author | amelia squires <[email protected]> | 2025-10-14 21:46:38 -0500 |
|---|---|---|
| committer | amelia squires <[email protected]> | 2025-10-14 21:46:38 -0500 |
| commit | af09c42e8067dfc832f7e1dce92860e1022c75fa (patch) | |
| tree | a444ec4586f9b1c54ea6680ffee2dc940644427d /tests | |
| parent | a67dc94484cf9869793fc1861914b800a6559a74 (diff) | |
tons of thread changed, more testing needed
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/kill.lua | 15 | ||||
| -rw-r--r-- | tests/tests.lua | 1 |
2 files changed, 15 insertions, 1 deletions
diff --git a/tests/kill.lua b/tests/kill.lua new file mode 100644 index 0000000..53344dc --- /dev/null +++ b/tests/kill.lua @@ -0,0 +1,15 @@ +local llby = require"lullaby" + +local t = llby.thread.async(function(res) + for i = 1, 50 do + print(i) + os.execute("sleep 1") + end +end) + +os.execute("sleep 5") + +print("killing") +t:close() +t:await() +print("after kill") diff --git a/tests/tests.lua b/tests/tests.lua index 6dae570..39c4d12 100644 --- a/tests/tests.lua +++ b/tests/tests.lua @@ -20,7 +20,6 @@ end local handle = assert(io.popen("find tests/units/".. search .." -type f")) for file in handle:lines() do - print(_G._locals) total = total + 1 local f = loadfile(file)() |
