I’ve found the
norminf(x) = maximum(abs, x)
@test x ≈ y rtol = 0.01 norm = norminf
approach to work well, and fail with a clearer error message than the
@test all(isapprox.(x, y, rtol = 0.01))
approach. Could it be made so that
@test x .≈ y rtol = 0.01
is equivalent to the norminf approach? This seems fairly intuitive to me. Currently the above line fails with error
Expression evaluated to non-Boolean
Expression: .≈(x, y, atol = 0.01)
Value: Bool[1, 1]