public class InsertTests extends TransactionFixture
dataSampler, model
docBuilder, ETS_PKG, featureInfo, featureTypes, reqEntity, rspEntity, supportedBindings, TNS_PREFIX, wfsClient, wfsMetadata, wfsVersion
Constructor and Description |
---|
InsertTests() |
Modifier and Type | Method and Description |
---|---|
static String |
addRandomName(Element feature)
Adds a gml:name element to the given feature representation.
|
(package private) Node |
createFeatureInstance(QName featureType)
Creates a new representation of a feature instance.
|
void |
deleteInsertedFeatures()
Restores the WFS data store to its previous state by deleting all
features that were successfully inserted by test methods in this class.
|
static List<ResourceId> |
extractFeatureIdentifiers(Document entity,
WFS2.Transaction action)
Extracts a list of resource identifiers for features that were affected
by a successful transaction request.
|
void |
insertInvalidFeature()
[
Test ] Submits a Transaction request to insert a feature instance
of a type not recognized by the SUT. |
static UUID |
insertRandomIdentifier(Element feature)
Inserts a user-assigned gml:identifier element having a random UUID
value.
|
void |
insertSupportedFeature(ProtocolBinding binding,
QName featureType)
[
Test ] Submits a Transaction request to insert a feature instance
of a type supported by the SUT. |
buildTransactionRequest, initTransactionFixture, setModel, trxTestParameters
addAttributesOnTestFailure, allProtocolsAndFeatureTypes, bindingAndAvailFeatureTypeProductSet, extractBodyAsDocument, getFeatureTypes, getInstantiatedFeatureTypes, getProtocolBindings, initBaseFixture, initParser, setWfsClient
public void deleteInsertedFeatures()
public void insertSupportedFeature(ProtocolBinding binding, QName featureType)
Test
] Submits a Transaction request to insert a feature instance
of a type supported by the SUT. The test is run for all supported
Transaction request bindings and feature types. The response entity
(wfs:TransactionResponse) must be schema-valid and contain the
wfs:InsertResults element.binding
- A supported message binding.featureType
- A QName representing the qualified name of some feature type.public void insertInvalidFeature()
Test
] Submits a Transaction request to insert a feature instance
of a type not recognized by the SUT. An ExceptionReport (with status code
400) containing the exception code InvalidValue
is expected in
response.public static List<ResourceId> extractFeatureIdentifiers(Document entity, WFS2.Transaction action)
entity
- A Document representing a successful transaction response
entity (wfs:TransactionResponse).action
- The transaction results of interest.Node createFeatureInstance(QName featureType)
featureType
- A QName representing the qualified name of some feature type.public static UUID insertRandomIdentifier(Element feature)
feature
- An Element node representing a GML feature.public static String addRandomName(Element feature)
feature
- An Element node representing a GML feature.Copyright © 2022 Open Geospatial Consortium. All rights reserved.