mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-13 00:03:09 -04:00
Added unit test to check correct outcome of axisInverted()
This commit is contained in:
parent
c784c09f04
commit
55cb04c52c
@ -60,6 +60,7 @@ class TestQgsCoordinateReferenceSystem: public QObject
|
||||
void geographicFlag();
|
||||
void mapUnits();
|
||||
void setValidationHint();
|
||||
void axisInverted();
|
||||
private:
|
||||
void debugPrint( QgsCoordinateReferenceSystem &theCrs );
|
||||
// these used by createFromESRIWkt()
|
||||
@ -410,6 +411,22 @@ void TestQgsCoordinateReferenceSystem::setValidationHint()
|
||||
debugPrint( myCrs );
|
||||
}
|
||||
|
||||
void TestQgsCoordinateReferenceSystem::axisInverted()
|
||||
{
|
||||
// this is used by WMS 1.3 to determine whether to switch axes or not
|
||||
|
||||
QgsCoordinateReferenceSystem crs;
|
||||
crs.createFromOgcWmsCrs( "EPSG:4326" ); // WGS 84 with inverted axes
|
||||
QVERIFY( crs.axisInverted() );
|
||||
|
||||
crs.createFromOgcWmsCrs( "CRS:84" ); // WGS 84 without inverted axes
|
||||
QVERIFY( !crs.axisInverted() );
|
||||
|
||||
crs.createFromOgcWmsCrs( "EPSG:32633" ); // "WGS 84 / UTM zone 33N" - projected CRS without invertex axes
|
||||
QVERIFY( !crs.axisInverted() );
|
||||
}
|
||||
|
||||
|
||||
void TestQgsCoordinateReferenceSystem::debugPrint(
|
||||
QgsCoordinateReferenceSystem &theCrs )
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user