OpenLayers OpenLayers

Ticket #1183: test_Style.patch

File test_Style.patch, 0.9 kB (added by ahocevar, 8 months ago)

with this patch, tests also run in IE.

  • tests/test_Style.html

    old new  
    2121         
    2222        var layer = new OpenLayers.Layer.Vector("layer"); 
    2323          
    24         var baseStyle = {externalGraphic: "bar${foo}.png"}; 
     24        var baseStyle = OpenLayers.Util.extend( 
     25                OpenLayers.Feature.Vector.style["default"], 
     26                {externalGraphic: "bar${foo}.png"}); 
    2527         
    2628        var style = new OpenLayers.Style(baseStyle); 
    2729         
     
    5961        // now the rule should not apply 
    6062         
    6163        createdStyle = style.createStyle(feature); 
    62         t.eq(createdStyle.fillColor, undefined, "Correct style for rule that does not apply to fid=\"2\"."); 
     64        t.eq(createdStyle.fillColor, baseStyle.fillColor, "Correct style for rule that does not apply to fid=\"2\"."); 
    6365         
    6466    } 
    6567