MCPcopy
hub / github.com/django/django / test02_bad_wkt

Method test02_bad_wkt

tests/gis_tests/gdal_tests/test_srs.py:222–231  ·  view source on GitHub ↗

Testing initialization on invalid WKT.

(self)

Source from the content-addressed store, hash-verified

220 SpatialReference(s.wkt)
221
222 def test02_bad_wkt(self):
223 "Testing initialization on invalid WKT."
224 for bad in bad_srlist:
225 try:
226 srs = SpatialReference(bad)
227 srs.validate()
228 except (SRSException, GDALException):
229 pass
230 else:
231 self.fail('Should not have initialized on bad WKT "%s"!')
232
233 def test03_get_wkt(self):
234 "Testing getting the WKT."

Callers

nothing calls this directly

Calls 2

validateMethod · 0.95
SpatialReferenceClass · 0.90

Tested by

no test coverage detected