[Commits] r218 - in sandbox/opengeo/drake/trunk: core/tests/widgets examples
commits at geoext.org
commits at geoext.org
Thu Mar 12 16:08:31 CET 2009
Author: sbenthall
Date: 2009-03-12 16:08:31 +0100 (Thu, 12 Mar 2009)
New Revision: 218
Modified:
sandbox/opengeo/drake/trunk/core/tests/widgets/Popup.html
sandbox/opengeo/drake/trunk/examples/popup.html
Log:
minor changes/cleaning of popup example and tests
Modified: sandbox/opengeo/drake/trunk/core/tests/widgets/Popup.html
===================================================================
--- sandbox/opengeo/drake/trunk/core/tests/widgets/Popup.html 2009-03-11 21:08:01 UTC (rev 217)
+++ sandbox/opengeo/drake/trunk/core/tests/widgets/Popup.html 2009-03-12 15:08:31 UTC (rev 218)
@@ -159,44 +159,6 @@
}
-/*
- function test_readRecords(t) {
- t.plan(9);
- // setup
- var reader, features, info, records;
- reader = new GeoExt.data.FeatureReader({}, [
- {'name': 'foo'},
- {'name': 'bar'}
- ]);
- features = [
- new OpenLayers.Feature.Vector(null, {
- 'foo': 'foo_0',
- 'bar': 'bar_0'
- }),
- new OpenLayers.Feature.Vector()
- ];
- features[0].fid = 1;
- features[0].state = OpenLayers.State.INSERT;
- features[1].fid = 2;
- features[1].state = OpenLayers.State.DELETE;
- // 8 tests
- info = reader.readRecords(features);
- records = info.records;
- t.eq(info.totalRecords, 2, 'readRecords returns correct number of records');
- t.eq(records[0].get('foo'), 'foo_0', 'readRecords correctly set feature properties in record');
- t.eq(records[0].get('fid'), 1, 'readRecords correctly set feature fid in record');
- t.eq(records[0].get('state'), OpenLayers.State.INSERT, 'readRecords correctly set feature state in record');
- t.ok(records[0].get('feature') == features[0], 'readRecords correctly set feature in record');
- t.eq(records[1].get('fid'), 2, 'readRecords correctly set feature fid in record (no properties case)');
- t.eq(records[1].get('state'), OpenLayers.State.DELETE, 'readRecords correctly set feature state in record (no properties case)');
- t.ok(records[1].get('feature') == features[1], 'readRecords correctly set feature in record (no properties case)');
- // 1 test
- reader.totalRecords = 20;
- info = reader.readRecords(features);
- t.eq(info.totalRecords, 20,
- "readRecords returns correct number of records");
- }
-*/
</script>
<body>
<div id="map"></div>
Modified: sandbox/opengeo/drake/trunk/examples/popup.html
===================================================================
--- sandbox/opengeo/drake/trunk/examples/popup.html 2009-03-11 21:08:01 UTC (rev 217)
+++ sandbox/opengeo/drake/trunk/examples/popup.html 2009-03-12 15:08:31 UTC (rev 218)
@@ -73,7 +73,7 @@
mapwin.show();
- mapPanel = mapwin.items.items[0]; //gross path :(
+ mapPanel = mapwin.items.get(0);
select = new OpenLayers.Control.SelectFeature(vector, {
More information about the Commits
mailing list