OUnitState
type !'worker next_test_case_t =
| Not_enough_worker
| Try_again
| Next_test_case of OUnitTest.path * OUnitTest.test_fun * 'worker
| Finished
type !'worker test_running = {
test_length : OUnitTest.test_length;
deadline : time;
next_health_check : time;
worker : 'worker;
}
type !'worker t = {
tests_planned : (OUnitTest.path * (OUnitTest.test_length * OUnitTest.test_fun))
list;
tests_running : (OUnitTest.path * 'worker test_running) list;
tests_passed : (OUnitTest.result_full * OUnitTest.result_list) list;
idle_workers : 'worker list;
chooser : OUnitChooser.chooser;
cache : OUnitCache.cache;
health_check_interval : time;
}
val health_check_interval : float OUnitConf.var
val create :
OUnitConf.conf ->
OUnitChooser.chooser ->
(OUnitTest.path * OUnitTest.test_length * OUnitTest.test_fun) list ->
'a t
val maybe_dump_cache : OUnitConf.conf -> 'a t -> 'a t
val add_test_results :
OUnitConf.conf ->
(OUnitTest.result_full * OUnitTest.result_list) ->
'a t ->
'a t
val test_finished :
OUnitConf.conf ->
(OUnitTest.result_full * OUnitTest.result_list) ->
'a ->
'a t ->
'a t
val count_worker : 'a t -> int
val count_tests_running : 'a t -> int
val get_workers : 'a t -> 'a list
val get_idle_workers : 'a t -> 'a list
val is_idle_worker : 'a -> 'a t -> bool
val get_tests_running : 'a t -> OUnitTest.path list
val next_test_case :
OUnitConf.conf ->
(OUnitTest.path, OUnitTest.result) OUnitLogger.logger ->
'a t ->
'a next_test_case_t * 'a t
val get_results : 'a t -> OUnitTest.result_full list
val get_worker_need_health_check : 'a t -> (OUnitTest.path option * 'a) list
val update_test_activity : OUnitTest.path -> 'a t -> 'a t
val get_worker_timed_out :
'a t ->
(OUnitTest.path * OUnitTest.test_length * 'a) list
val timeout : 'a t -> float