git-svn-id: http://svn.openlayers.org/trunk/openlayers@11145 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
27 lines
735 B
HTML
27 lines
735 B
HTML
<html>
|
|
<head>
|
|
<script src="../../lib/OpenLayers.js"></script>
|
|
<script type="text/javascript">
|
|
function test_Handler_Box_destroy(t) {
|
|
t.plan(1);
|
|
var map = new OpenLayers.Map('map');
|
|
var control = new OpenLayers.Control();
|
|
map.addControl(control);
|
|
var handler = new OpenLayers.Handler.Box(control);
|
|
handler.activate();
|
|
try {
|
|
handler.destroy();
|
|
t.ok(true, "destroying the box handler should not raise any error");
|
|
} catch(err) {
|
|
t.fail("destroying the box handler causes trouble: " + err);
|
|
}
|
|
map.destroy();
|
|
}
|
|
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<div id="map" style="width: 300px; height: 150px;"/>
|
|
</body>
|
|
</html>
|