Commit 94013a1b authored by Philippe Veber's avatar Philippe Veber
Browse files

tk/Convergence_tree: added test

parent 74b927db
......@@ -97,6 +97,14 @@ let leaves tree =
in
node `Ancestral tree []
let%test "leaves computed in correct order" =
match from_file "../../data/besnard2009/besnard2009.nhx" with
| Ok t ->
List.equal String.equal
(List.take (leaves t) 4 |> List.map ~f:fst)
[ "Chrysithr" ; "Ele.bald" ; "Ele.bal2" ; "Ele.bal4" ]
| Error (`Msg msg) -> failwith msg
let rec transfer_condition_to_branches t =
let category : _ Tree.t -> condition = function
| Leaf (_, c) -> c
......
......@@ -3,6 +3,8 @@
(libraries biotk biocaml.ez ocaml-r.graphics ocaml-r.grDevices phylogenetics
phylogenetics.convergence)
(inline_tests
(deps ../../tests/data/gemma_output.tsv ../../tests/data/gemma_alignment.fa))
(deps ../../tests/data/gemma_output.tsv
../../tests/data/gemma_alignment.fa
../../data/besnard2009/besnard2009.nhx))
(preprocess
(pps ppx_jane ppx_inline_test ppx_deriving.show)))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment