[Phylobase-commits] r865 - pkg/tests
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Mar 14 21:20:39 CET 2014
Author: francois
Date: 2014-03-14 21:20:38 +0100 (Fri, 14 Mar 2014)
New Revision: 865
Modified:
pkg/tests/phylotorture.R
pkg/tests/phylotorture.Rout.save
Log:
simplifying output of torture test to make it pass R check
Modified: pkg/tests/phylotorture.R
===================================================================
--- pkg/tests/phylotorture.R 2014-03-14 18:21:03 UTC (rev 864)
+++ pkg/tests/phylotorture.R 2014-03-14 20:20:38 UTC (rev 865)
@@ -13,7 +13,9 @@
p1[[i]] <- try(phylo4(e),silent=TRUE)
}
OKvals <- sapply(p1, class) != "try-error"
-table(sapply(p1[!OKvals], as.character))
+## table(sapply(p1[!OKvals], as.character)) # I think this is causing issues with
+## R check because of different width of terminal/output, trying something simpler:
+message(unique(sapply(p1[!OKvals], as.character)))
if (any(OKvals)) {
p2 <- p1[OKvals]
Modified: pkg/tests/phylotorture.Rout.save
===================================================================
--- pkg/tests/phylotorture.Rout.save 2014-03-14 18:21:03 UTC (rev 864)
+++ pkg/tests/phylotorture.Rout.save 2014-03-14 20:20:38 UTC (rev 865)
@@ -54,14 +54,15 @@
7: In checkTree(object) : Tree contains singleton nodes.
8: In checkTree(object) : Tree contains singleton nodes.
> OKvals <- sapply(p1, class) != "try-error"
-> table(sapply(p1[!OKvals], as.character))
+> ## table(sapply(p1[!OKvals], as.character)) # I think this is causing issues with
+> ## R check because of different width of terminal/output, trying something simpler:
+> message(unique(sapply(p1[!OKvals], as.character)))
+Error in .local(x, ...) :
+ Tips incorrectly labeled. Nodes incorrectly labeled.
+Error in names(res) <- switch(type, tip = 1:ntips, internal = seq(from = ntips + :
+ 'names' attribute [2] must be the same length as the vector [1]
+Error in .local(x, ...) : Nodes incorrectly labeled.
- Error in .local(x, ...) : Nodes incorrectly labeled. \n
- 1
- Error in .local(x, ...) : \n Tips incorrectly labeled. Nodes incorrectly labeled. \n
- 7
-Error in names(res) <- switch(type, tip = 1:ntips, internal = seq(from = ntips + : \n 'names' attribute [2] must be the same length as the vector [1]\n
- 2
>
> if (any(OKvals)) {
+ p2 <- p1[OKvals]
@@ -220,4 +221,4 @@
>
> proc.time()
user system elapsed
- 5.799 0.194 5.971
+ 5.708 0.195 5.887
More information about the Phylobase-commits
mailing list