summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2025-11-08 00:49:37 +0800
committerruki <[email protected]>2025-11-08 00:49:37 +0800
commitaad9c244ead90ba767e41cc971812d469130f41f (patch)
tree1cd3c633cb4de68942bbdbb35b80fddc4ac35cca
parenta9567b1b432e8f2d352963f66bde3cf07b863c5a (diff)
improve tests
-rw-r--r--tests/modules/os/async_scheduler.lua15
1 files changed, 4 insertions, 11 deletions
diff --git a/tests/modules/os/async_scheduler.lua b/tests/modules/os/async_scheduler.lua
index d6818c9c5..0a201f8f7 100644
--- a/tests/modules/os/async_scheduler.lua
+++ b/tests/modules/os/async_scheduler.lua
@@ -23,17 +23,10 @@ function main()
end
scheduler.co_start(function ()
- local copydir = root .. "_copy"
- os.cp(root, copydir, {async = true})
- assert(os.isdir(copydir))
- os.rm(copydir, {async = true})
- print("async copy complete: %s", copydir)
+ print("async find all files in programdir...")
+ local files = os.files(path.join(os.programdir(), "**"), {async = true})
+ print("files: %d", #files)
+ print("async find all finished")
end)
end)
-
- scheduler.co_group_wait(group)
- print("all async tasks finished")
- os.rm(root, {async = true})
- print("async scheduler test finished")
end
-