MCPcopy
hub / github.com/django/django / assertTextarea

Method assertTextarea

tests/gis_tests/test_geoforms.py:312–319  ·  view source on GitHub ↗

Makes sure the wkt and a textarea are in the content

(self, geom, rendered)

Source from the content-addressed store, hash-verified

310 self.assertIn("gis/js/OLMapWidget.js", str(form_instance.media))
311
312 def assertTextarea(self, geom, rendered):
313 """Makes sure the wkt and a textarea are in the content"""
314
315 self.assertIn("<textarea ", rendered)
316 self.assertIn("required", rendered)
317 ogr = geom.ogr
318 ogr.transform(3857)
319 self.assertIn(escape(ogr.json), rendered)
320
321 # map_srid in openlayers.html template must not be localized.
322 @override_settings(USE_THOUSAND_SEPARATOR=True)

Callers 7

test_pointfieldMethod · 0.95
test_multipointfieldMethod · 0.95
test_linestringfieldMethod · 0.95
test_polygonfieldMethod · 0.95

Calls 2

escapeFunction · 0.90
transformMethod · 0.45

Tested by

no test coverage detected