From b0196d12c554cb4f2cc9637af98b9f772ce3c4ba Mon Sep 17 00:00:00 2001 From: jemorrison Date: Thu, 19 Sep 2024 14:21:31 -0700 Subject: [PATCH] fix test test_offset.py ruff issue --- jwst/cube_build/tests/test_offset.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/jwst/cube_build/tests/test_offset.py b/jwst/cube_build/tests/test_offset.py index 58149a5bd5b..e14da0fdf37 100644 --- a/jwst/cube_build/tests/test_offset.py +++ b/jwst/cube_build/tests/test_offset.py @@ -3,7 +3,6 @@ """ import pytest -import sys import math import asdf from stdatamodels.jwst import datamodels @@ -159,8 +158,8 @@ def test2_offset_file_config(tmp_cwd, miri_ifushort_short_2files, offset_file): miri_ifushort_short_2files[0].meta.filename = 'test3.fits' step.offset_file = offset_file - with pytest.raises(Exception): - offsets = step.check_offset_file() + with pytest.raises(ValueError): + step.check_offset_file() def test_offset_file_units(tmp_cwd, miri_ifushort_short_2files, offset_file_arcmin): @@ -172,7 +171,7 @@ def test_offset_file_units(tmp_cwd, miri_ifushort_short_2files, offset_file_arcm step.offset_file = offset_file_arcmin with pytest.raises(Exception): - offsets = step.check_offset_file() + step.check_offset_file() def test_read_offset_file(miri_ifushort_short_2files, offset_file): """ Test offset file has been read in correctly"""