Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added comment in `geoapp` tests about PostGIS 2.0 change in ST_NumGeo…

…metries.
  • Loading branch information...
commit db78086b4540f968620ffe465174d7094267f04b 1 parent 950e618
@jbronn jbronn authored
Showing with 6 additions and 3 deletions.
  1. +6 −3 django/contrib/gis/tests/geoapp/tests.py
View
9 django/contrib/gis/tests/geoapp/tests.py
@@ -575,10 +575,13 @@ def test_make_line(self):
def test_num_geom(self):
"Testing the `num_geom` GeoQuerySet method."
# Both 'countries' only have two geometries.
- for c in Country.objects.num_geom(): self.assertEqual(2, c.num_geom)
+ for c in Country.objects.num_geom():
+ self.assertEqual(2, c.num_geom)
+
for c in City.objects.filter(point__isnull=False).num_geom():
- # Oracle will return 1 for the number of geometries on non-collections,
- # whereas PostGIS will return None.
+ # Oracle and PostGIS 2.0+ will return 1 for the number of
+ # geometries on non-collections, whereas PostGIS < 2.0.0
+ # will return None.
if postgis and connection.ops.spatial_version < (2, 0, 0):
self.assertIsNone(c.num_geom)
else:

0 comments on commit db78086

Please sign in to comment.
Something went wrong with that request. Please try again.