From ec5df48d012f847def4ece67c9295f30e6a30168 Mon Sep 17 00:00:00 2001 From: Robbie Mackay Date: Fri, 14 Dec 2012 12:34:26 +1300 Subject: [PATCH] Add unit test for OpenLayers.Layer.Bing.protocol * Test that attribution logo uses correct protocol * Test that tile urls use correct protocol --- tests/Layer/Bing.html | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/tests/Layer/Bing.html b/tests/Layer/Bing.html index 69525df7a5..d930e719b0 100644 --- a/tests/Layer/Bing.html +++ b/tests/Layer/Bing.html @@ -178,6 +178,37 @@ t.ok(clone instanceof OpenLayers.Layer.Bing, "clone is a Layer.Bing instance"); } + function test_protocol(t) + { + t.plan(5); + + var map = new OpenLayers.Map("map"); + layer = new OpenLayers.Layer.Bing(options); + map.addLayer(layer); + map.zoomToMaxExtent(); + var tile = layer.tileQueue[0]; + + t.delay_call(5, function() { + t.ok(OpenLayers.Util.indexOf(layer.attribution, '