Incorrect expect_equal in narray/tests/testthat
spkaluzny opened this issue · comments
In the testthat tests for the narray package there are two calls to testthat::expect_equal
that pass in three objects as arguments to compare but the expect_equal
function only compares the first two arguments, object
and expected
. The third argument ends up getting passed as ...
to compare
which ends up passing it to all.equal
where it is ignored.
The problem expressions are line 11 in narray/tests/testthat/test-dimnames.r:
expect_equal(dimnames(a), dimnames(a, drop=FALSE), dn[1])
And line 60 in narray/tests/testthat/test-intersect.r:
expect_equal(DF, DF3, DFref, tolerance=1e-5, scale=1)
You can see that the third object is ignored by passing in any nonsense value and expect_equal does not complain e.g.
expect_equal(DF, DF3, "blort", tolerance=1e-5, scale=1)
Thanks, I must have missed that when I fixed the rest of the incorrect expects.
Fixed now.