Add required_dependency decorator
@@ -10,6 +10,7 @@ from gammapy.utils.regions import (
make_concentric_annulus_sky_regions,
make_orthogonal_rectangle_sky_regions,
)
+from gammapy.utils.testing import requires_dependency
def get_simple_dataset_on_off():
@@ -42,6 +43,7 @@ def make_horizontal_boxes(wcs):
)
+@requires_dependency("iminuit")
def test_profile_content():
mapdataset_onoff = get_simple_dataset_on_off()
wcs = mapdataset_onoff.counts.geom.wcs
@@ -75,6 +77,7 @@ def test_profile_content():
assert_allclose(ul, [111.31, 111.31], atol=1e-2)
+@requires_dependency("iminuit")
def test_radial_profile():
dataset = get_simple_dataset_on_off()
geom = dataset.counts.geom
@@ -110,6 +113,7 @@ def test_radial_profile():
assert_allclose(ul, [72.074, 72.074], rtol=1e-3)
+@requires_dependency("iminuit")
def test_radial_profile_one_interval():
dataset = get_simple_dataset_on_off()
geom = dataset.counts.geom
