Skip to content

Commit 4e885ba

Browse files
committed
Remove some stray case changes
1 parent 34afcd3 commit 4e885ba

File tree

2 files changed

+1
-14
lines changed

2 files changed

+1
-14
lines changed

src/astro_image_display_api/dummy_viewer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ def set_colormap(self, map_name: str, image_label: str | None = None) -> None:
155155
image_label = self._resolve_image_label(image_label)
156156
if image_label not in self._images:
157157
raise ValueError(f"Image label '{image_label}' not found. Please load an image first.")
158-
self._images[image_label].colormap = map_name.lower()
158+
self._images[image_label].colormap = map_name
159159

160160
set_colormap.__doc__ = ImageViewerInterface.set_colormap.__doc__
161161

src/astro_image_display_api/widget_api_test.py

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -730,19 +730,6 @@ def test_set_get_colormap(self, data):
730730
self.image.set_colormap(new_cmap, image_label='test')
731731
assert self.image.get_colormap(image_label='test') == new_cmap
732732

733-
def test_set_get_colormap_map_name_case_insensitive(self, data):
734-
# Check that the colormap can be set with a name that is not
735-
# case-sensitive.
736-
self.image.load_image(data, image_label='test')
737-
cmap_desired = 'GrAy'
738-
self.image.set_colormap(cmap_desired)
739-
assert self.image.get_colormap() == cmap_desired.lower()
740-
741-
# Set the colormap with a different case
742-
new_cmap = "Viridis"
743-
self.image.set_colormap(new_cmap, image_label='test')
744-
assert self.image.get_colormap(image_label='test') == 'viridis'
745-
746733
def test_set_colormap_errors(self, data):
747734
# Check that setting a colormap raises an error if the colormap
748735
# is not in the list of allowed colormaps.

0 commit comments

Comments
 (0)