Skip to content

Commit

Permalink
Merge pull request #5818 from mapserver/geographika-patch-1
Browse files Browse the repository at this point in the history
Update Projection WKT string
  • Loading branch information
geographika committed Jun 6, 2019
2 parents 356a1e1 + 04a9711 commit 36175e0
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions mapscript/python/tests/cases/map_test.py
Expand Up @@ -289,16 +289,22 @@ def testSetSize(self):

class MapSetWKTTestCase(MapTestCase):

def xtestOGCWKT(self):
self.map.setWKTProjection('PROJCS["unnamed", PROJECTION["Albers_Conic_Equal_Area"], '
'PARAMETER["standard_parallel_1", 65], PARAMETER["standard_parallel_2", 55], '
'PARAMETER["latitude_of_center", 0], PARAMETER["longitude_of_center", -153], '
'PARAMETER["false_easting", -4943910.68], PARAMETER["false_northing", 0]]')
def testOGCWKT(self):
self.map.setWKTProjection('''PROJCS["unnamed",GEOGCS["WGS 84",DATUM["WGS_1984",
SPHEROID["WGS 84",6378137,298.257223563]],
PRIMEM["Greenwich",0],
UNIT["Degree",0.0174532925199433]],
PROJECTION["Albers_Conic_Equal_Area"],
PARAMETER["standard_parallel_1", 65], PARAMETER["standard_parallel_2", 55],
PARAMETER["latitude_of_center", 0], PARAMETER["longitude_of_center", -153],
PARAMETER["false_easting", -4943910.68], PARAMETER["false_northing", 0],
UNIT["metre",1.0]
]''')
proj4 = self.map.getProjection()

assert proj4.find('+proj=aea') != -1
assert proj4.find('+ellps=WGS84') != -1
assert (mapscript.projectionObj(proj4)).getUnits() != mapscript.MS_DD
assert proj4.find('+datum=WGS84') != -1
assert mapscript.projectionObj(proj4).getUnits() != mapscript.MS_DD

def testESRIWKT(self):
self.map.setWKTProjection('ESRI::PROJCS["Pulkovo_1995_GK_Zone_2", GEOGCS["GCS_Pulkovo_1995", '
Expand Down

0 comments on commit 36175e0

Please sign in to comment.