From 0cca5bbafb43071f5d3b3e8434b22f814ee2f884 Mon Sep 17 00:00:00 2001 From: Pablo Zubieta Date: Tue, 1 Aug 2017 18:41:39 -0500 Subject: [PATCH] Add a test for issue #4 --- test/runtests.jl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/runtests.jl b/test/runtests.jl index 2e3a9d0..a4e67d4 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -44,3 +44,10 @@ end end @test HCubature.countevals(HCubature.Trivial()) == 1 end + +@testset "axischoosing" begin + #Issue #4 + let f = x -> 1.0 + (x[1] * x[3] * sin(x[2]))^2 + @test hcubature(f, (0.0,0.0,-0.2), (0.2,2π,0.2), rtol=1e-6)[1] ≈ (22502//140625)*π rtol=1e-6 + end +end