summaryrefslogtreecommitdiff
path: root/misc/openlayers/tests/Control/NavToolbar.html
diff options
context:
space:
mode:
authorChris Schlaeger <chris@linux.com>2015-10-17 21:36:38 +0200
committerChris Schlaeger <chris@linux.com>2015-10-17 21:36:38 +0200
commite30f267181d990947e67909de4809fa941698c85 (patch)
tree46e9f94c2b3699ed378963b420b8a8d361286ea1 /misc/openlayers/tests/Control/NavToolbar.html
parente763ceb183f389fcd314a4a6a712d87c9d4cdb32 (diff)
downloadpostrunner-e30f267181d990947e67909de4809fa941698c85.zip
Upgrading openlayers to 3.x
Diffstat (limited to 'misc/openlayers/tests/Control/NavToolbar.html')
-rw-r--r--misc/openlayers/tests/Control/NavToolbar.html45
1 files changed, 0 insertions, 45 deletions
diff --git a/misc/openlayers/tests/Control/NavToolbar.html b/misc/openlayers/tests/Control/NavToolbar.html
deleted file mode 100644
index 9b3bbec..0000000
--- a/misc/openlayers/tests/Control/NavToolbar.html
+++ /dev/null
@@ -1,45 +0,0 @@
-<html>
-<head>
- <script src="../OLLoader.js"></script>
- <script type="text/javascript">
- var map;
- function test_Control_NavToolbar_constructor (t) {
- t.plan( 4 );
- control = new OpenLayers.Control.NavToolbar();
- t.ok( control instanceof OpenLayers.Control.NavToolbar, "new OpenLayers.Control.NavToolbar returns object" );
- t.eq( control.displayClass, "olControlNavToolbar", "displayClass is correct" );
- t.ok( control.controls[0] instanceof OpenLayers.Control.Navigation, "NavToolbar contains Control.Navigation object" );
- t.ok( control.controls[1] instanceof OpenLayers.Control.ZoomBox, "NavToolbar contains Control.ZoomBox object" );
- }
- function test_Control_NavToolbar_addControl (t) {
- t.plan( 6 );
- map = new OpenLayers.Map('map');
- control = new OpenLayers.Control.NavToolbar();
- t.ok( control instanceof OpenLayers.Control.NavToolbar, "new OpenLayers.Control.NavToolbar returns object" );
- t.ok( map instanceof OpenLayers.Map, "new OpenLayers.Map creates map" );
- map.addControl(control);
- t.ok( control.map === map, "Control.map is set to the map object" );
- t.ok( map.controls[4] === control, "map.controls contains control" );
- t.eq( parseInt(control.div.style.zIndex), map.Z_INDEX_BASE['Control'] + 7, "Control div zIndexed properly" );
- t.eq( parseInt(map.viewPortDiv.lastChild.style.zIndex), map.Z_INDEX_BASE['Control'] + 7, "Viewport div contains control div" );
- // t.eq( control.div.style.top, "6px", "Control div top located correctly by default");
-
- }
-
- function test_Control_NavToolbar_defaultControl (t) {
- t.plan( 1 );
- var map = new OpenLayers.Map('map');
-
- var nav = new OpenLayers.Control.NavToolbar();
- map.addControl(nav);
-
- t.eq(nav.controls[0].active, true, "First control is active" );
-
- map.destroy();
- }
- </script>
-</head>
-<body>
- <div id="map" style="width: 1024px; height: 512px;"/>
-</body>
-</html>