MCPcopy
hub / github.com/django/django / test_scale

Method test_scale

tests/gis_tests/geo3d/tests.py:347–356  ·  view source on GitHub ↗

Testing Scale() function on Z values.

(self)

Source from the content-addressed store, hash-verified

345 self.assertAlmostEqual(ref_length_3d, inter3d.length.m, tol)
346
347 def test_scale(self):
348 """
349 Testing Scale() function on Z values.
350 """
351 self._load_city_data()
352 # Mapping of City name to reference Z values.
353 zscales = (-3, 4, 23)
354 for zscale in zscales:
355 for city in City3D.objects.annotate(scale=Scale("point", 1.0, 1.0, zscale)):
356 self.assertEqual(city_dict[city.name][2] * zscale, city.scale.z)
357
358 def test_translate(self):
359 """

Callers

nothing calls this directly

Calls 3

ScaleClass · 0.90
_load_city_dataMethod · 0.80
annotateMethod · 0.80

Tested by

no test coverage detected