Skip to content

Commit

Permalink
removed no longer applicable test
Browse files Browse the repository at this point in the history
Signed-off-by: Quinn Guerin <qguerin@icr-team.com>
  • Loading branch information
Quinn Guerin committed Jul 9, 2024
1 parent c25ccee commit 874bd6e
Showing 1 changed file with 0 additions and 28 deletions.
28 changes: 0 additions & 28 deletions public/model/customLayerFunctions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,34 +92,6 @@ describe('CustomLayerFunctions', () => {
expect(map.addLayer).toHaveBeenCalledWith(expect.any(Object));
});

it('should update an existing layer', () => {
const updatedLayerConfig: CustomLayerSpecification = {
id: 'existing-layer',
source: {
// @ts-ignore
type: DASHBOARDS_CUSTOM_MAPS_LAYER_TYPE.TMS,
tiles: ['https://updatedtiles.example.com/{z}/{x}/{y}.png'],
attribution: 'Updated Test Attribution',
},
opacity: 50,
zoomRange: [0, 15],
visibility: 'visible',
};

CustomLayerFunctions.render(maplibreRef, updatedLayerConfig);

expect(map.setPaintProperty).toHaveBeenCalledWith(
updatedLayerConfig.id,
'raster-opacity',
updatedLayerConfig.opacity / 100
);
expect(map.setLayerZoomRange).toHaveBeenCalledWith(
updatedLayerConfig.id,
updatedLayerConfig.zoomRange[0],
updatedLayerConfig.zoomRange[1]
);
});

it('should convert zoomRange to a numeric array', () => {
const layerConfig = {
id: 'test-layer',
Expand Down

0 comments on commit 874bd6e

Please sign in to comment.