Skip to content

Commit

Permalink
Merge pull request #934 from mperrin/fix_test_case_float_check
Browse files Browse the repository at this point in the history
switch a test case float comparison to np.allclose for robustness
  • Loading branch information
BradleySappington authored Nov 22, 2024
2 parents 4c4cbf8 + 4d9af0a commit 540a751
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion webbpsf/tests/test_detectors.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ def test_ipc_basic_effect_on_psf_fwhm():
for extname in ['OVERSAMP', 'DET_SAMP']:
fwhm_ipc = poppy.measure_fwhm(psf_withipc, ext=extname)
fwhm_noipc = poppy.measure_fwhm(psf_noipc, ext=extname)
assert fwhm_ipc == fwhm_noipc, f'Adding IPC should not have any effect on the {extname} data.'
assert np.isclose(fwhm_ipc, fwhm_noipc), f'Adding IPC should not have any effect on the {extname} data.'
print(f'test ok for {extname}')

for extname in ['OVERDIST', 'DET_DIST']:
Expand Down

0 comments on commit 540a751

Please sign in to comment.