diff --git a/types/openlayers/openlayers-tests.ts b/types/openlayers/openlayers-tests.ts index 6e28ad4cd2..d631a9e9bb 100644 --- a/types/openlayers/openlayers-tests.ts +++ b/types/openlayers/openlayers-tests.ts @@ -418,6 +418,14 @@ feature.setStyle(styleArray); feature.setStyle(featureStyleFunction); feature.setStyle(styleFunction); feature.setProperties(object); +const nullStyleFunction = (feature: (ol.Feature|ol.render.Feature), resolution: number): null => { + return null; +}; +const nullFeatureStyleFunction = (resolution: number): null => { + return null; +}; +feature.setStyle(nullStyleFunction); +feature.setStyle(nullFeatureStyleFunction); // // ol.View @@ -573,6 +581,10 @@ const vectorLayer: ol.layer.Vector = new ol.layer.Vector({ zIndex: -1 }); +vectorLayer.setStyle(nullStyleFunction); +vectorLayer.setStyle(null); +vectorLayer.setStyle(undefined); + // // ol.layer.VectorTile //