always include field type in DescribeFeatureType fields. With

modifications from tschaub. r=tschaub (closes #1202)


git-svn-id: http://svn.openlayers.org/trunk/openlayers@9106 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
ahocevar
2009-03-20 17:26:40 +00:00
parent 7e35022dff
commit 0a6ea3125d
2 changed files with 9 additions and 2 deletions
+8 -2
View File
@@ -4,7 +4,7 @@
<script type="text/javascript">
function test_read_WFSDescribeFeatureType(t) {
t.plan(36);
t.plan(39);
var parser = new OpenLayers.Format.WFSDescribeFeatureType();
@@ -281,6 +281,9 @@
t.eq(res.featureTypes[0].properties[0].name, 'cat',
"The first attribute has name cat");
t.eq(res.featureTypes[0].properties[0].type.split(":")[1], 'long',
"The first attribute has type long with a prefix");
t.eq(res.featureTypes[0].properties[0].localType, 'long',
"The first attribute has localType long");
@@ -344,8 +347,11 @@
t.eq(res.featureTypes[0].properties[1].name, "STATE_NAME",
"name of 2nd property of 1st featureType should be 'STATE_NAME'");
t.eq(res.featureTypes[0].properties[1].type, "xs:string",
"type of 2nd property of 1st featureType should be 'xs:string'");
t.eq(res.featureTypes[0].properties[1].localType, "string",
"type of 2nd property of 1st featureType should be 'string'");
"localType of 2nd property of 1st featureType should be 'string'");
t.eq(res.featureTypes[0].properties[1].restriction.maxLength, "25",
"the maxLength restriction should be 25");