mirror of
https://github.com/c-cube/moonpool.git
synced 2025-12-06 03:05:30 -05:00
update tests a bit
This commit is contained in:
parent
d15bfb07f2
commit
9ab9df78c9
2 changed files with 4 additions and 1 deletions
|
|
@ -31,7 +31,8 @@ let run ~psize ~n ~seq ~niter () : unit =
|
|||
)
|
||||
in
|
||||
Printf.printf "fib %d = %d\n%!" n res
|
||||
done
|
||||
done;
|
||||
if not seq then Pool.shutdown (Lazy.force pool)
|
||||
|
||||
let () =
|
||||
let n = ref 40 in
|
||||
|
|
|
|||
|
|
@ -4,8 +4,10 @@ let ( let@ ) = ( @@ )
|
|||
|
||||
(* test proper resource handling *)
|
||||
let () =
|
||||
let@ () = Trace_tef.with_setup () in
|
||||
let a = Atomic.make 0 in
|
||||
for _i = 1 to 1_000 do
|
||||
let@ _sp = Trace.with_span ~__FILE__ ~__LINE__ "loop.step" in
|
||||
(* give a chance to domains to die *)
|
||||
if _i mod 100 = 0 then Thread.delay 0.8;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue