Skip to content

Commit

Permalink
Semi-gratuitous coverage of a missed branch
Browse files Browse the repository at this point in the history
  • Loading branch information
rmjarvis committed May 8, 2020
1 parent f10145c commit 4fd6d8a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions galsim/fitswcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -910,6 +910,8 @@ def __init__(self, file_name=None, dir=None, hdu=None, header=None, compression=
self.projection = 'lambert'
elif self.wcs_type == 'ARC':
self.projection = 'postel'
else:
raise ValueError("Invalid wcs_type in _data")
return

# Read the file if given.
Expand Down
1 change: 1 addition & 0 deletions tests/test_wcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -2261,6 +2261,7 @@ def test_gsfitswcs():

assert_raises(TypeError, galsim.GSFitsWCS)
assert_raises(TypeError, galsim.GSFitsWCS, file_name, header='dummy')
assert_raises(ValueError, galsim.GSFitsWCS, _data=('invalid',0,0,0,0,0,0))

@timer
def test_tanwcs():
Expand Down

0 comments on commit 4fd6d8a

Please sign in to comment.