OGC logo
Reference number of document: OGC 07-134r2

Version: 1.0.0

OGC KML 2.2 – Abstract Test Suite

B. Hagemark

Google

R. Martell

Editor 
Galdos Systems, Inc.

J. Parr-Pearson

Galdos Systems, Inc.

T. Wilson

Galdos Systems, Inc.

Copyright (c) 2008 Open Geospatial Consortium, Inc. All Rights Reserved.

Revision History
Revision 1.0.02008-04-11
Corresponds to the final approved OGC specification; includes minor editorial revisions in the wake of the 60-day TC review.
Revision 1.0.0-rc22008-01-21
Updated to address public review comments (see OGC 08-004); minor editorial revisions.
Revision 1.0.0-rc12007-11-05
Includes test cases for the candidate OGC standard (OGC 07-147r1).

Overview

This document is an abstract test suite (ATS): a compendium of abstract test cases that provide a basis for verifying the structure and content of OGC KML 2.2 instance documents. Three conformance levels are defined; each level builds on the preceding ones:

  • Level 1 - includes test cases covering all requirements to be satisfied by a minimally conformant KML document;

  • Level 2 - as for Level 1, plus test cases addressing recommended requirements;

  • Level 3 - as for Level 2, plus test cases covering suggested constraints that are informative in nature.

Note that the prefix "kml" in this document designates the KML 2.2 namespace having the name "http://www.opengis.net/kml/2.2".

Source documents


Table of Contents

Conformance Level 1
Conformance Level 2
Conformance Level 3

Conformance Level 1

Purpose

Conformance Level 1 includes test cases corresponding to absolute requirements; a KML document must satisfy all assertions at this level to be minimally conformant.

ATC 1: Root element

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/RootElement
Test purposeVerify that the root element of the document has [local name] = "kml" and [namespace name] = "http://www.opengis.net/kml/2.2".
Test methodPass if all assertions are satisfied; fail otherwise. This test checks that the XML document is indeed an OGC KML document. If this test fails, all remaining tests are skipped.
Reference
  • OGC-07-147r2: cl. 7.1.2

Test typeBasic

ATC 2: XML Schema constraints

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/XmlSchemaConstraints
Test purposeCheck that the document is well-formed and schema-valid.
Test methodPass if the document satisfies all schema constraints; fail otherwise.
Reference
Test typeBasic

ATC 3: Geometry coordinates

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Geometry-Coordinates
Test purposeVerify that a kml:coordinates element contains a list of white space-separated 2D or 3D tuples that contain comma-separated decimal values (lon,lat[,hgt]).
Test methodPass if all kml:coordinates elements contain 2D/3D tuples containing decimal values conforming to the xsd:decimal type; fail otherwise. White space consists of one or more of the following characters: space (U+0020), carriage return (U+000D), line feed (U+000A), or tab (U+0009). The relevant coordinate reference system (CRS) is defined in Annex B of the OGC KML 2.2 specification.
Reference
Test typeBasic

ATC 4: TimeSpan

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/TimeSpan
Test purpose

Verify that a TimeSpan element satisfies all of the following constraints:

  1. it includes at least one child element (kml:begin or kml:end);

  2. if it is a definite interval (both kml:begin and kml:end are present), then the begin value is earlier than the end value.

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 15.2.2

Test typeBasic

ATC 5: TimeStamp

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/TimeStamp
Test purposeVerify that a kml:TimeStamp element has a child kml:when element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 15.3.2

Test typeBasic

ATC 6: Style reference

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/StyleReference
Test purpose

Check that a kml:styleUrl element satisfies all of the following constraints:

  1. its value is a valid relative or absolute URL that refers to a shared style definition (any element that substitutes for kml:AbstractStyleSelectorGroup);

  2. if the reference is an absolute URI, the value conforms to the 'http' or 'file' URI schemes;

  3. it includes a fragment identifier conforming to the shorthand pointer syntax as defined in the W3C XPointer framework.

Test methodPass if all applicable assertions are satisfied; fail otherwise. A relative URL is resolved according to the reference resolution algorithm described in section 5 of RFC 3986.
Reference
Test typeBasic

ATC 7: Shared style definition

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/SharedStyle
Test purpose

Confirm that a 'shared' style definition (any element that may substitute for kml:AbstractStyleSelectorGroup) satisfies all of the following constraints:

  • its parent element is kml:Document;

  • it has an 'id' attribute value.

Test methodPass if all assertions are satisfied; fail otherwise. Shared styles include kml:Style and kml:StyleMap elements.
Reference
  • OGC-07-147r2: cl. 6.4

Test typeBasic

ATC 8: Region - LatLonAltBox

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Region-LatLonAltBox
Test purpose

Verify that the content of a kml:LatLonAltBox element satisfies all of the following constraints:

  1. kml:north > kml:south;

  2. kml:east > kml:west;

  3. kml:minAltitude <= kml:maxAltitude;

  4. if kml:minAltitude and kml:maxAltitude are both present, then kml:altitudeMode does not have the value "clampToGround".

Test methodPass if all applicable assertions are satisfied; fail otherwise. The default envelope for a region of interest is the entire surface of the EGM96 geoid. By testing north > south and east > west, we are testing for a non-zero area.
Reference
  • OGC-07-147r2: cl. 9.15.2

Test typeBasic

ATC 9: Link elements

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Link-Elements
Test purpose

Check that a link element (of type kml:LinkType) satisfies all of the following constraints:

  1. if present, the child kml:refreshInterval element has a positive value (> 0);

  2. if present, the child kml:viewRefreshTime element has a positive value (> 0);

  3. if present, the child kml:viewBoundScale element has a positive value (> 0).

Test methodPass if a link element (kml:Link, kml:AbstractOverlayType/kml:Icon) satisfies all applicable constraints; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.1.3.3.1

  • OGC-07-147r2: cl. 13.1.3.5.1

  • OGC-07-147r2: cl. 13.1.3.6.1

Test typeBasic

ATC 10: Link referent

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/LinkReferent
Test purpose

Confirm that a link element refers to the correct resource type, according to one of the following cases:

  1. if the parent element is kml:NetworkLink - a KML or KMZ resource;

  2. if the parent element is kml:Model - a textured 3D object resource;

  3. if the parent element is kml:GroundOverlay, kml:ScreenOverlay, or kml:PhotoOverlay - an image resource

Test methodPass if all link elements (kml:Link, kml:AbstractOverlayType/kml:Icon) have correct referents; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.12.3.3

  • OGC-07-147r2: cl. 10.9.3.5.1

  • OGC-07-147r2: cl. 11.1.3.3

Test typeBasic

ATC 11: LatLonBox

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/LatLonBox
Test purpose

Verify that a kml:LatLonBox element satisfies all of the following constraints:

  1. it contains the kml:north, kml:south, kml:east, and kml:west elements;

  2. kml:north > kml:south (compare character information items);

  3. kml:east > kml:west (compare character information items).

Test methodPass if the assertion is satisfied; fail otherwise. The default envelope for a kml:GroundOverlay is the entire surface of the WGS 84 ellipsoid. By testing north > south and east > west, we are testing for a non-zero area.
Reference
  • OGC-07-147r2: cl. 11.3.2

Test typeBasic

ATC 12: Geometry - extrude

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Geometry-Extrude
Test purpose

Check that if the kml:extrude element has the value "true", then the value of kml:altitudeMode is not "clampToGround".

Test methodPass if the assertion is satisfied; fail otherwise. This applies to the following elements: kml:Point, kml:LineString, kml:LinearRing (but NOT if it occurs within a Polygon), and kml:Polygon.
Reference
  • OGC-07-147r2: cl. 10.4.1.1.2

Test typeBasic

ATC 13: Geometry - tessellate

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Geometry-Tessellate
Test purpose

Confirm that if the kml:tessellate element has the value "true", then the value of kml:altitudeMode is "clampToGround" (default value).

Test methodPass if the assertion is satisfied; fail otherwise. This applies to the following elements: kml:LineString, kml:LinearRing (but NOT if it occurs within a Polygon), and kml:Polygon.
Reference
  • OGC-07-147r2: cl. 10.6.2

Test typeBasic

ATC 14: Point

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Point
Test purposeCheck that the kml:coordinates element in a kml:Point geometry contains exactly one coordinate tuple.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.3.2

Test typeBasic

ATC 15: LineString

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/LineString
Test purposeVerify that the kml:coordinates element in a kml:LineString geometry contains at least two coordinate tuples.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.7.3.4.1

Test typeBasic

ATC 16: LinearRing - control points

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/LinearRing-ControlPoints
Test purposeCheck that the kml:coordinates element in a kml:LinearRing geometry contains at least 4 coordinate tuples, where the first and last are identical (i.e. they constitute a closed figure).
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.7.5.4.1

Test typeBasic

ATC 17: Polygon boundary

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/PolygonBoundary
Test purpose

Verify that the boundary of a kml:Polygon element satisfies all of the following constraints:

  1. if it is not a descendant of kml:Update, then the kml:Polygon has a child kml:outerBoundaryIs element;

  2. each interior boundary defines a hole in the Polygon (that is, each inner ring lies within the exterior boundary).

Test methodPass if all assertions are satisfied; fail otherwise. This test case reflects the essential definition of a polygon; no particular line orientations are assumed. The relevant polygons can be identified using this XPath expression: //kml:Polygon[not(ancestor::kml:Update)].
Reference
  • OGC-07-147r2: cl. 10.8.2

Test typeBasic

ATC 18: Icon - href

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Icon-href
Test purposeVerify that the kml:Icon/kml:href element refers to an image resource.
Test methodPass if the assertion is satisfied; fail otherwise. The image format must correspond to a registered image media type (PNG, JPEG, and GIF images are commonly used for this purpose). Applies to kml:Icon elements in both kml:IconStyle and kml:AbstractOverlayType contexts.
Reference
Test typeBasic

ATC 19: ViewVolume - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/ViewVolume-Minimal
Test purposeVerify that a kml:ViewVolume element includes at least the following child elements: kml:leftFov, kml:rightFov, kml:bottomFov, kml:topFov, and kml:near (non-negative value).
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 11.5.2

  • OGC-07-147r2: cl. 11.5.3.5

Test typeBasic

ATC 20: NetworkLinkControl - minRefreshPeriod

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/NetworkLinkControl-MinRefreshPeriod
Test purposeVerify that a kml:minRefreshPeriod element (occurs in kml:NetworkLinkControl) is non-negative (>=0).
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.2.3.1.1

Test typeBasic

ATC 21: Empty object

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/EmptyObject
Test purposeVerify that a KML object that is not a descendant of kml:Update is either (a) not empty, or (b) has an 'id' attribute value (so it can be easily updated).
Test methodPass if the assertion is satisfied; fail otherwise. The relevant context is //kml:AbstractObjectType[not(ancestor::kml:Update)].
Reference
  • OGC-07-147r2: cl. 8.1.3.1.1

Test typeBasic

ATC 22: Update - targetHref

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Update-targetHref
Test purpose

Check that the value of the kml:Update/kml:targetHref element satisfies all of the following constraints:

  1. it is an absolute URL that refers to a KML or KMZ resource;

  2. the value matches the retrieval URI for an existing NetworkLink element (kml:NetworkLink/kml:Link/kml:href).

Test methodPass if all applicable assertions are satisfied; fail otherwise. This modifies the behaviour of a referring NetworkLink.
Reference
  • OGC-07-147r2: cl. 13.4.2

Test typeBasic

ATC 23: Identification of update target

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/UpdateTarget
Test purposeCheck that a KML object which is a grandchild of kml:Update satisfies the following constraints: (a) it includes a 'targetId' attribute value that identifies the object to be updated, and (b) it does not have an 'id' attribute.
Test methodPass if the assertion is satisfied; fail otherwise. Examine the content of all kml:Create, kml:Delete and kml:Change elements.
Reference
  • OGC-07-147r2: cl. 13.3.2

Test typeBasic

ATC 24: PhoneNumber

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/PhoneNumber
Test purposeCheck that the value of the kml:phoneNumber element is a 'tel' URI that conforms to RFC 3966.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
Test typeBasic

ATC 25: Schema

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Schema
Test purposeCheck that a kml:Schema element has an 'id' attribute value.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.8.2

Test typeBasic

ATC 26: Schema - SimpleField

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Schema-SimpleField
Test purpose

Verify that a kml:SimpleField element satisfies all of the following constraints:

  1. it has a 'name' attribute;

  2. the value of the 'type' attribute is one of the following XML Schema data types:

    • xsd:string

    • xsd:int

    • xsd:unsignedInt

    • xsd:short

    • xsd:unsignedShort

    • xsd:float

    • xsd:double

    • xsd:boolean

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
Test typeBasic

ATC 27: ExtendedData - SchemaData

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/ExtendedData-SchemaData
Test purpose

Confirm that a kml:SchemaData element satisfies all of the following constraints:

  1. the 'schemaUrl' attribute value is a URL with a fragment component that refers to a kml:Schema element;

  2. all kml:SimpleData child elements have a 'name' attribute that matches the name of a declared kml:SimpleField element in the corresponding Schema;

  3. the values of all kml:SimpleData child elements conform to their declared types.

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.4.2

  • OGC-07-147r2: cl. 9.5.2

Test typeBasic

ATC 28: ExtendedData - Data

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/ExtendedData-Data
Test purposeCheck that the value of the 'name' attribute is unique within the context of the parent kml:ExtendedData element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.3.2

Test typeBasic

ATC 29: Alias

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Alias
Test purpose

Verify that a kml:Alias element satisfies the following assertions:

  1. the value of the child kml:targetHref element is a URI reference to an image (texture) resource;

  2. the value of the child kml:sourceHref element corresponds to a file reference appearing within the 3D object resource referenced in the preceding sibling kml:Link element.

Test methodPass if all assertions are satisfied; fail otherwise. The source is expected to be a textual (possibly XML) resource.
Reference
  • OGC-07-147r2: cl. 10.14.3.1.1

Test typeBasic

ATC 30: atom:author

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/atom-author
Test purpose

Check that an atom:author element satisfies all of the following assertions:

  1. the content of the child atom:uri element is an IRI reference;

  2. the content of the child atom:email element conforms to the "addr-spec" production in RFC 2822.

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
Test typeBasic

ATC 31: atom:link

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/atom-link
Test purposeCheck that the value of the atom:link/@rel attribute is "related".
Test methodPass if the assertion is satisfied; fail otherwise. If the attribute is not present, the link must be interpreted as if @rel = "alternate" (i.e. the referent is an alternate version of the resource). The value "related" simply signifies a generic relationship.
Reference
Test typeBasic

ATC 32: Orientation - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Orientation-Minimum
Test purposeVerify that if a kml:Orientation element is not a descendant of kml:Update, then it contains at least one of the following elements: kml:heading, kml:tilt, or kml:roll.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.11.2

Test typeBasic

ATC 33: GroundOverlay

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/GroundOverlay
Test purposeVerify that a kml:GroundOverlay with an kml:altitudeMode value of "absolute" includes a kml:altitude element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.17.2

Test typeBasic

ATC 34: Model

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Model
Test purpose

Check that a kml:Model element satisfies all of the following constraints:

  1. it contains the kml:Link and kml:Location elements;

  2. if it is not a descendant of kml:Update and the target resource refers to any texture files, then there must be a kml:ResourceMap/kml:Alias for each related texture file.

Test methodPass if all applicable assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.9.3

Test typeBasic

ATC 35: PhotoOverlay - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/PhotoOverlay-Minimal
Test purposeCheck that if a kml:PhotoOverlay element is not a descendant of kml:Update, then it includes all of the following child elements: kml:Icon, kml:ViewVolume, kml:Point, and kml:Camera.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 11.4.2

Test typeBasic

ATC 36: Pair

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Pair
Test purposeCheck that if a kml:Pair element is not a descendant of kml:Update, then it contains (a) a kml:key element, and (b) at least one of kml:styleURL element or any element that substitutes for kml:AbstractStyleSelectorGroup.
Test methodPass if the assertion is satisfied; fail otherwise. kml:AbstractStyleSelectorGroup elements are typically kml:Style or kml:StyleMap.
Reference
  • OGC-07-147r2: cl. 12.4.2

Test typeBasic

ATC 37: ItemIcon

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/ItemIcon
Test purposeCheck that if a kml:ItemIcon element is not a descendant of kml:Update, then it has a kml:href child element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.14.2

Test typeBasic

ATC 38: LookAt

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/LookAt
Test purpose

Check that a kml:LookAt element satisfies all of the following constraints:

  1. if it is not a descendant of kml:Update, it contains all of the following child elements: kml:longitude, kml:latitude, and kml:range;

  2. 0 <= kml:tilt <= 90;

  3. if kml:altitudeMode does not have the value "clampToGround", then the kml:altitude element is present.

Test methodPass if the applicable assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.17.2

  • OGC-07-147r2: cl. 14.3.2

  • OGC-07-147r2: cl. 14.3.4.5.1

Test typeBasic

ATC 39: Lod

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Lod
Test purpose

Check that a kml:Lod element satisfies all of the following constraints:

  1. if it is not a descendant of kml:Update, it contains the kml:minLodPixels element;

  2. kml:minLodPixels < kml:maxLodPixels (where a value of -1 denotes infinity).

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.18.2

Test typeBasic

ATC 40: Link

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Link
Test purposeCheck that if a kml:Link or a kml:Icon element is not a descendant of kml:Update, then it contains a kml:href child element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.1.2

Test typeBasic

ATC 41: Region

Identifierhttp://www.opengis.net/kml/2.2/atc/level-1/Region
Test purposeConfirm that if a kml:Region element is not a descendant of kml:Update, it contains the kml:LatLonAltBox and kml:Lod elements.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.13.2

Test typeBasic

Conformance Level 2

Purpose

Conformance Level 2 includes all Level 1 tests plus test cases covering requirements that should be satisfied by a KML document. Non-conformance at this level may hinder the utility, portability, or interoperability of the document.

ATC 42: PolyStyle

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/PolyStyle
Test purposeCheck that if a kml:PolyStyle element is not a descendant of kml:Update, it contains at least one of the following elements: kml:color, kml:colorMode, kml:fill, or kml:outline.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.12.2

Test typeBasic

ATC 43: Coordinates - altitudeMode

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Coordinates-altitudeMode
Test purpose

Confirm that a kml:coordinates or kml:Location element includes a third coordinate tuple (altitude) if its sibling kml:altitudeMode element does NOT have the value "clampToGround".

Test methodPass if the assertion is satisfied; fail otherwise. Applies to the control points in kml:AbstractGeometryType/kml:coordinates and kml:Model/kml:Location.
Reference
  • OGC-07-147r2: cl. 9.17.2

Test typeBasic

ATC 44: Scale - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Scale-Minimal
Test purposeVerify that if a kml:Scale element is not a descendant of kml:Update, it contains at least one of the following elements: kml:x, kml:y, or kml:z.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.12.2

Test typeBasic

ATC 45: KML - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Kml-Minimal
Test purposeVerify that the root element (kml:kml) contains at least one child element: kml:NetworkLinkControl or any element that substitutes for kml:AbstractFeatureType.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 7.1.2

Test typeBasic

ATC 46: ViewFormat

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ViewFormat
Test purposeVerify a kml:viewFormat contains at least one parameter.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.1.2

Test typeBasic

ATC 47: httpQuery

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/HttpQuery
Test purposeVerify a kml:httpQuery contains at least one parameter.
Test methodPass if the httpQuery has at least one of the allowable parameters; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.1.2

Test typeBasic

ATC 48: LinearRing in Polygon

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/LinearRingInPolygon
Test purposeVerify that a kml:LinearRing element, when appearing within a kml:Polygon, does not contain any of the following elements: kml:extrude, kml:tesselate, or kml:altitudeMode.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.5.2

Test typeBasic

ATC 49: Data

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Data
Test purposeCheck that the kml:Data element has both a 'name' attribute and a kml:value child element.
Test methodPass if the assertion is satisfiedt; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.3.2

Test typeBasic

ATC 50: ResourceMap - Alias

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ResourceMap-Alias
Test purposeVerify that a kml:ResourceMap element contains at least one kml:Alias child element, and that each Alias element has a unique kml:sourceHref value.
Test methodPass if all assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.13.2

Test typeBasic

ATC 51: Link refresh values

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/LinkRefresh
Test purpose

Check that a kml:Link or a kml:Icon element (of type kml:LinkType) satisfies all of the following constraints:

  1. if the kml:refreshInterval element is present, the kml:refreshMode value must be "onInterval";

  2. if the kml:viewRefresh element is present, the kml:refreshMode value must be "onStop".

Test methodPass if all relevant assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 13.1.3.2.1

Test typeBasic

ATC 52: PhotoOverlay

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/PhotoOverlay
Test purposeCheck that if a kml:PhotoOverlay element includes a kml:Icon/kml:href element containing [x], [y], and [level] parameters, then it also includes a child kml:ImagePyramid element; the converse must also be true.
Test methodPass if the assertion is satisfied; fail otherwise. The parameters are embedded within the URL; i.e, http://server.company.com/bigphoto/$[level]/row_$[x]_column_$[y].jpg. Check for the kml:ImagePyramid when the x, y, level parameters are present, or if the kml:ImagePyramid is present check for the x, y, level parameters.
Reference
  • OGC-07-147r2: cl. 11.4.3

Test typeBasic

ATC 53: GroundOverlay - minimal content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/GroundOverlay-Minimal
Test purposeVerify that if a kml:GroundOverlay element is not a descendant of kml:Update, it contains a kml:LatLonBox element (with kml:north, kml:south, kml:east, kml:west).
Test methodPass if the assertion is satisfied; fail otherwise. The presence of north, south, east, and west indicates the Overlay draws a polygon.
Reference
  • OGC-07-147r2: cl. 11.2.3.1

Test typeBasic

ATC 54: Camera

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Camera
Test purpose

Check that a kml:Camera element satisfies all of the following constraints:

  1. if it is not a descendant of kml:Update, then the following child elements are present: kml:latitude, kml:longitude, and kml:altitude;

  2. the value of kml:altitudeMode is not "clampToGround".

Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 14.2.2

Test typeBasic

ATC 55: Location

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Location
Test purpose

Check that a kml:Location element satisfies all of the following constraints:

  1. it contains the kml:longitude and kml:latitude elements;

  2. if the parent kml:Model element has a kml:altitudeMode value that is not "clampToGround", then the kml:altitude element must also be present.

Test methodPass if all applicable assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.17.2

  • OGC-07-147r2: cl. 10.9.2,

  • OGC-07-147r2: cl. 10.10.2

Test typeBasic

ATC 56: Overlay

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Overlay
Test purposeCheck that if any element that substitutes for kml:AbstractOverlayType is not a descendant of kml:Update, then it contains a kml:Icon child element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 11.2.2

Test typeBasic

ATC 57: ScreenOverlay

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ScreenOverlay
Test purposeCheck that if a kml:ScreenOverlay element is not a descendant of kml:Update, then it has a kml:screenXY child element.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 11.7.2

Test typeBasic

ATC 58: BalloonStyle

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/BalloonStyle
Test purposeCheck that if a kml:BalloonStyle element is not a descendant of kml:Update, it is not empty.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.6.2

Test typeBasic

ATC 59: ExtendedData

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ExtendedData
Test purposeCheck that a kml:ExtendedData element is not empty.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.2.2

Test typeBasic

ATC 60: Folder

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Folder
Test purposeCheck that if a kml:Folder element is not a descendant of kml:Update, then it is not empty.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.10.2

Test typeBasic

ATC 61: IconStyle

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/IconStyle
Test purposeCheck that if a kml:IconStyle element is NOT a descendant of kml:Update, it is not empty.
Test methodPass if all applicable assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.8.2

  • OGC-07-147r2: cl. 12.9.2

Test typeBasic

ATC 62: ImagePyramid

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ImagePyramid
Test purpose

Check that if a kml:ImagePyramid element is not a descendantof kml:Update, it satisfies all of the following constraints:

  1. it has the kml:maxWidth and kml:maxHeight child elements;

  2. the kml:tileSize value is a power of 2.

Test methodPass if all assertions are satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 11.6.2

Test typeBasic

ATC 63: LabelStyle

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/LabelStyle
Test purposeCheck that if a kml:LabelStyle element is not a descendant of kml:Update, it has at least one of the following child elements: kml:color, kml:colorMode, or kml:scale.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.10.2

Test typeBasic

ATC 64: ListStyle

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/ListStyle
Test purposeCheck that if a kml:ListStyle element is not a descendant of kml:Update, it has at least one of the following child elements: kml:listItemType, kml:bgColor, or kml:ItemIcon.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.13.2

Test typeBasic

ATC 65: Style

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Style
Test purposeCheck that if a kml:Style element is not a descendant of kml:Update, it is not empty.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.2.2

Test typeBasic

ATC 66: MultiGeometry

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/MultiGeometry
Test purposeCheck that if a kml:MultiGeometry element is not a descendant of kml:Update, it contains two or more geometry elements.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.2.2

Test typeBasic

ATC 67: Placemark

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/Placemark
Test purposeCheck that if a kml:Placemark element is not a descendant of kml:Update, it includes a geometry element (any element that substitutes for kml:AbstractGeometryGroup.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.11.2

Test typeBasic

ATC 68: StyleMap

Identifierhttp://www.opengis.net/kml/2.2/atc/level-2/StyleMap
Test purposeCheck that if a kml:StyleMap element is not a descendant of kml:Update, it contains two kml:Pair elements where one key value is "normal" and the other key value is "highlight".
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 12.3.2

Test typeBasic

Conformance Level 3

Purpose

Conformance Level 3 includes all Level 2 tests and introduces additional constraints of an informative nature; these are intended to signal the use of deprecated elements or to encourage alignment with existing (non-normative) standards or conventions.

ATC 69: Polygon - rings

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/PolygonRings
Test purposeConfirm that no two rings comprising the boundary of a kml:Polygon geometry cross.
Test methodPass if the assertion is satisfied; fail otherwise. The rings may intersect at a single point.
Reference
Test typeBasic

ATC 70: LinearRing - Simple

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/SimpleLinearRing
Test purposeCheck that a kml:LinearRing is a simple ring (that is, it does not cross itself).
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
Test typeBasic

ATC 71: BalloonStyle - color

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/BalloonStyle-color
Test purposeCheck for any occurrences of the (deprecated) kml:color element in kml:BalloonStyle elements.
Test methodPass if no kml:color elements occur in this context; fail otherwise. This element is deprecated in favour of kml:bgColor.
Reference
  • OGC-07-147r2: Annex A

Test typeBasic

ATC 72: Metadata

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/Metadata
Test purposeCheck for any occurrences of the (deprecated) kml:Metadata element.
Test methodPass if no kml:Metadata elements occur; fail otherwise. This element is deprecated in favour of kml:ExtendedData.
Reference
  • OGC-07-147r2: Annex A

Test typeBasic

ATC 73: Scale - full content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/Scale-Full
Test purposeVerify that a kml:Scale element includes all of the following child elements: kml:x, kml:y, and kml:z.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.12.2

Test typeBasic

ATC 74: Lod - fade extents

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/Lod-FadeExtents
Test purposeVerify the following constraint regarding the evaluation of fade extents: kml:minFadeExtent + kml:maxFadeExtent <= kml:maxLodPixels - kml:minLodPixels.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 9.18.2

Test typeBasic

ATC 75: Orientation - full content

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/Orientation-Full
Test purposeVerify that a kml:Orientation element includes the following child elements: kml:heading, kml:tilt, and kml:roll.
Test methodPass if the assertion is satisfied; fail otherwise.
Reference
  • OGC-07-147r2: cl. 10.11.2

Test typeBasic

ATC 76: Snippet

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/Snippet
Test purposeCheck for any occurrences of the (deprecated) kml:Snippet element.
Test methodPass if no kml:Snippet elements occur; fail otherwise. This element is deprecated in favour of kml:snippet.
Reference
  • OGC-07-147r2: Annex A

Test typeBasic

ATC 77: NetworkLink-Url

Identifierhttp://www.opengis.net/kml/2.2/atc/level-3/NetworkLink/Url
Test purposeCheck for any occurrences of the (deprecated) kml:Url element.
Test methodPass if no kml:Url elements occur as a child of kml:NetworkLink; fail otherwise. This element is deprecated in favour of kml:Link.
Reference
  • OGC-07-147r2: Annex A

Test typeBasic