@@ -27,17 +27,17 @@ type cmd =
2727 (* | Join*)
2828 | Spawn of cmd list [@@ deriving show { with_path = false }]
2929
30- let gen max_depth max_width =
31- let depth_gen = Gen. int_bound max_depth in
32- let width_gen = Gen. int_bound max_width in
33- Gen. sized_size depth_gen @@ Gen. fix (fun rgen n ->
30+ let gen max_height max_degree =
31+ let height_gen = Gen. int_bound max_height in
32+ let degree_gen = Gen. int_bound max_degree in
33+ Gen. sized_size height_gen @@ Gen. fix (fun rgen n ->
3434 match n with
3535 | 0 -> Gen. oneofl [Incr ;Decr ]
3636 | _ ->
3737 Gen. oneof
3838 [
3939 Gen. oneofl [Incr ;Decr ];
40- Gen. map (fun ls -> Spawn ls) (Gen. list_size width_gen (rgen (n/ 2 )))
40+ Gen. map (fun ls -> Spawn ls) (Gen. list_size degree_gen (rgen (n-1 )))
4141 ])
4242
4343let rec shrink_cmd = function
@@ -63,12 +63,12 @@ let rec dom_interp a = function
6363 let ds = List. map (fun c -> Domain. spawn (fun () -> dom_interp a c)) cs in
6464 List. iter Domain. join ds
6565
66- let t ~max_depth ~ max_width = Test. make
66+ let t ~max_height ~ max_degree = Test. make
6767 ~name: " domain_spawntree - with Atomic"
6868 ~count: 100
6969 ~retries: 10
70- (* ~print:show_cmd (gen max_depth max_width )*)
71- (make ~print: show_cmd ~shrink: shrink_cmd (gen max_depth max_width ))
70+ (* ~print:show_cmd (gen max_height max_degree )*)
71+ (make ~print: show_cmd ~shrink: shrink_cmd (gen max_height max_degree ))
7272
7373 ((* Util.fork_prop_with_timeout 30*) (* forking a fresh process starts afresh, it seems *)
7474 (fun c ->
@@ -85,4 +85,4 @@ let t ~max_depth ~max_width = Test.make
8585 else (Printf. printf " Failure \" %s\"\n %!" s; false )
8686 ))
8787;;
88- QCheck_base_runner. run_tests_main [t ~max_depth: 20 ~max_width :10 ]
88+ QCheck_base_runner. run_tests_main [t ~max_height: 5 ~max_degree :10 ]
0 commit comments