Package org.opengis.cite.gpkg12.features
Class FeaturesTests
java.lang.Object
org.opengis.cite.gpkg12.CommonFixture
org.opengis.cite.gpkg12.FeaturesFixture
org.opengis.cite.gpkg12.features.FeaturesTests
Defines test methods that apply to descriptive information about a GeoPackage's content
as it pertains to features.
Sources
- GeoPackage Encoding Standard - 2.1 Features (OGC 12-128r13) and OGC 12-128r14
- Author:
- Jeff Yutzler
-
Field Summary
Modifier and TypeFieldDescription(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
Fields inherited from class org.opengis.cite.gpkg12.FeaturesFixture
ALLOWED_GEOMETRY_TYPES, geomGEOMETRY, geomGEOMETRYCOLLECTION, geomLINESTRING, geomMULTILINESTRING, geomMULTIPOINT, geomMULTIPOLYGON, geomPOINT, geomPOLYGON
Fields inherited from class org.opengis.cite.gpkg12.CommonFixture
databaseConnection, dataSource, geopackageVersion, gpkgFile, ROOT_PKG_PATH
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Test case/opt/features/geometry_columns/data/data_values_geometry_columns
void
Test case/opt/features/geometry_columns/data/data_values_column_name
void
Test case/opt/features/geometry_columns/data/data_values_geometry_type_name
void
Test case/opt/features/geometry_columns/data/data_values_m
void
Test case/opt/features/geometry_columns/data/data_values_srs_id_match
void
Test case/opt/features/geometry_columns/data/data_values_table_name
and/opt/features/geometry_columns/data/data_values_srs_id
void
Test case/opt/features/geometry_columns/data/data_values_table_name
Verify that the table_name column values in the gpkg_geometry_columns table are valid.void
Test case/opt/features/geometry_columns/data/data_values_z
void
Test case/opt/features/geometry_columns/data/table_def
void
featureGeometryEncodingTesting
(String thisTableName, String thisColumnName, String geomType, Integer srs_id, byte z_flag, byte m_flag) Verify that geometries stored in feature table geometry columns are encoded in the StandardGeoPackageBinary format. and are consistent with the information specified in the gpkg_geometry_columns table for the feature type.void
Verify that the gpkg_contents table_name value table exists, and is apparently a feature table for every row with a data_type column value of 'features' Test Case/opt/features/contents/data/features_row
void
Test case/opt/features/vector_features/data/feature_table_geometry_column_type
void
A GeoPackage MAY contain tables or updateable views containing vector features.void
Test case/opt/features/vector_features/data/feature_table_one_geometry_column
A DataProvider that supplies feature instance test methods with content from gpkg_geometry_columns such that feature instance test methods may verify feature internal content is consistent with gpkg_geometry_columns information.void
setUp()
Sets up variables used across methodsMethods inherited from class org.opengis.cite.gpkg12.FeaturesFixture
getAllowedGeometryTypes
Methods inherited from class org.opengis.cite.gpkg12.CommonFixture
checkPrimaryKey, close, getGeopackageVersion, getPrimaryKeyColumn, getTestName, initCommonFixture, isExtendedType, setTestName, validateClassEnabled
-
Field Details
-
errorDetected19
int errorDetected19 -
errorDetected32
int errorDetected32 -
errorDetected33
int errorDetected33 -
errorDetectedNSG19b
int errorDetectedNSG19b -
errorDetected66
int errorDetected66 -
errorDetected67
int errorDetected67 -
errorDetected78
int errorDetected78 -
errorDetected20
int errorDetected20
-
-
Constructor Details
-
FeaturesTests
public FeaturesTests()
-
-
Method Details
-
setUp
Sets up variables used across methods- Throws:
SQLException
- if there is a database error
-
getFeaturesWithGeometryInfo
@DataProvider(name="feature-geometry-information") public Iterator<Object[]> getFeaturesWithGeometryInfo()A DataProvider that supplies feature instance test methods with content from gpkg_geometry_columns such that feature instance test methods may verify feature internal content is consistent with gpkg_geometry_columns information.- Returns:
- An Iterator over an array containing a set of objects representing the information needed to process tests against geometry BLOB information
-
features_contents_data_features_row
Verify that the gpkg_contents table_name value table exists, and is apparently a feature table for every row with a data_type column value of 'features' Test Case/opt/features/contents/data/features_row
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureTableIntegerPrimaryKey
A GeoPackage MAY contain tables or updateable views containing vector features. Every such feature table or view in a GeoPackage SHALL have a column with column type INTEGER and PRIMARY KEY AUTOINCREMENT column constraints per EXAMPLE : Sample Feature Table or View Definition and sample_feature_table Table Definition SQL (Informative). Test case/opt/features/vector_features/data/feature_table_integer_primary_key
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryEncodingTesting
public void featureGeometryEncodingTesting(String thisTableName, String thisColumnName, String geomType, Integer srs_id, byte z_flag, byte m_flag) throws SQLException Verify that geometries stored in feature table geometry columns are encoded in the StandardGeoPackageBinary format. and are consistent with the information specified in the gpkg_geometry_columns table for the feature type. Also verify that the geometry information is consistent with other elements of the geopackage as per specified test requirements. In order to optimize processing as much as possible, all tests involving the feature instance geometry element are performed within this block. The entry to this test is via an iterator operating on each feature table - hence the test reports will be specific to each feature table processed. Test Case for tests 19, 20, 32, 33, 66 (partial) 67, 78/opt/features/geometry_encoding/data/blob /opt/features/geometry_encoding/data/core_types_existing_sparse_data /opt/features/vector_features/data/data_values_geometry_type /opt/features/vector_features/data/data_value_geometry_srs_id /extensions/geometry_types/extension_name /reg_ext/features/spatial_indexes/implementation/sql_functions
- Parameters:
thisTableName
- The feature table name being processedthisColumnName
- The feature column name (the geometry column) being processed; as specified in the gpkg_geometry_columns entry table associated with this featuregeomType
- The geometry type as specified in the gpkg_geometry_columns entry table associated with this featuresrs_id
- The srs identifier as specified in the gpkg_geometry_columns entry table associated with this featurez_flag
- The z flag as specified in the gpkg_geometry_columns entry table associated with this featurem_flag
- The m flag as specified in the gpkg_geometry_columns entry table associated with this feature- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsTableDef
Test case/opt/features/geometry_columns/data/table_def
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValues
Test case/opt/features/geometry_columns/data/data_values_geometry_columns
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesTableName
Test case/opt/features/geometry_columns/data/data_values_table_name
and/opt/features/geometry_columns/data/data_values_srs_id
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesTableNameNEW
Test case/opt/features/geometry_columns/data/data_values_table_name
Verify that the table_name column values in the gpkg_geometry_columns table are valid.- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesColumnName
Test case/opt/features/geometry_columns/data/data_values_column_name
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesSrsId
Test case/opt/features/geometry_columns/data/data_values_srs_id_match
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesGeometryType
Test case/opt/features/geometry_columns/data/data_values_geometry_type_name
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesZ
Test case/opt/features/geometry_columns/data/data_values_z
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureGeometryColumnsDataValuesM
Test case/opt/features/geometry_columns/data/data_values_m
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureTableOneGeometryColumn
Test case/opt/features/vector_features/data/feature_table_one_geometry_column
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-
featureTableGeometryColumnType
Test case/opt/features/vector_features/data/feature_table_geometry_column_type
- Throws:
SQLException
- If an SQL query causes an error- See Also:
-