| 1 | ======================================================================
|
|---|
| 2 | ERROR: test_closepolygons (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 3 | Testing closing Polygon objects.
|
|---|
| 4 | ----------------------------------------------------------------------
|
|---|
| 5 | Traceback (most recent call last):
|
|---|
| 6 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 245, in test_closepolygons
|
|---|
| 7 | self.assertEqual(OGRGeometry('POINT(2.5 2.5)'), poly.centroid)
|
|---|
| 8 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 657, in centroid
|
|---|
| 9 | capi.get_centroid(self.ptr, p.ptr)
|
|---|
| 10 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 118, in check_errcode
|
|---|
| 11 | check_err(result, cpl=cpl)
|
|---|
| 12 | File "/media/sf_django/django/contrib/gis/gdal/error.py", line 73, in check_err
|
|---|
| 13 | raise e(msg)
|
|---|
| 14 | django.contrib.gis.gdal.error.GDALException: OGR failure.
|
|---|
| 15 |
|
|---|
| 16 | ======================================================================
|
|---|
| 17 | ERROR: test_difference (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 18 | Testing difference().
|
|---|
| 19 | ----------------------------------------------------------------------
|
|---|
| 20 | Traceback (most recent call last):
|
|---|
| 21 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 362, in test_difference
|
|---|
| 22 | d2 = a.difference(b)
|
|---|
| 23 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 493, in difference
|
|---|
| 24 | return self._geomgen(capi.geom_diff, other)
|
|---|
| 25 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 471, in _geomgen
|
|---|
| 26 | return OGRGeometry(gen_func(self.ptr, other.ptr), self.srs)
|
|---|
| 27 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 84, in check_geom
|
|---|
| 28 | raise GDALException('Invalid geometry pointer returned from "%s".' % func.__name__)
|
|---|
| 29 | django.contrib.gis.gdal.error.GDALException: Invalid geometry pointer returned from "OGR_G_Difference".
|
|---|
| 30 |
|
|---|
| 31 | ======================================================================
|
|---|
| 32 | ERROR: test_intersection (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 33 | Testing intersects() and intersection().
|
|---|
| 34 | ----------------------------------------------------------------------
|
|---|
| 35 | Traceback (most recent call last):
|
|---|
| 36 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 375, in test_intersection
|
|---|
| 37 | i2 = a.intersection(b)
|
|---|
| 38 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 500, in intersection
|
|---|
| 39 | return self._geomgen(capi.geom_intersection, other)
|
|---|
| 40 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 471, in _geomgen
|
|---|
| 41 | return OGRGeometry(gen_func(self.ptr, other.ptr), self.srs)
|
|---|
| 42 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 84, in check_geom
|
|---|
| 43 | raise GDALException('Invalid geometry pointer returned from "%s".' % func.__name__)
|
|---|
| 44 | django.contrib.gis.gdal.error.GDALException: Invalid geometry pointer returned from "OGR_G_Intersection".
|
|---|
| 45 |
|
|---|
| 46 | ======================================================================
|
|---|
| 47 | ERROR: test_polygons (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 48 | Testing Polygon objects.
|
|---|
| 49 | ----------------------------------------------------------------------
|
|---|
| 50 | Traceback (most recent call last):
|
|---|
| 51 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 218, in test_polygons
|
|---|
| 52 | x, y = poly.centroid.tuple
|
|---|
| 53 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 657, in centroid
|
|---|
| 54 | capi.get_centroid(self.ptr, p.ptr)
|
|---|
| 55 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 118, in check_errcode
|
|---|
| 56 | check_err(result, cpl=cpl)
|
|---|
| 57 | File "/media/sf_django/django/contrib/gis/gdal/error.py", line 73, in check_err
|
|---|
| 58 | raise e(msg)
|
|---|
| 59 | django.contrib.gis.gdal.error.GDALException: OGR failure.
|
|---|
| 60 |
|
|---|
| 61 | ======================================================================
|
|---|
| 62 | ERROR: test_srs (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 63 | Testing OGR Geometries with Spatial Reference objects.
|
|---|
| 64 | ----------------------------------------------------------------------
|
|---|
| 65 | Traceback (most recent call last):
|
|---|
| 66 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 286, in test_srs
|
|---|
| 67 | diff = a.difference(b)
|
|---|
| 68 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 493, in difference
|
|---|
| 69 | return self._geomgen(capi.geom_diff, other)
|
|---|
| 70 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 471, in _geomgen
|
|---|
| 71 | return OGRGeometry(gen_func(self.ptr, other.ptr), self.srs)
|
|---|
| 72 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 84, in check_geom
|
|---|
| 73 | raise GDALException('Invalid geometry pointer returned from "%s".' % func.__name__)
|
|---|
| 74 | django.contrib.gis.gdal.error.GDALException: Invalid geometry pointer returned from "OGR_G_Difference".
|
|---|
| 75 |
|
|---|
| 76 | ======================================================================
|
|---|
| 77 | ERROR: test_symdifference (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 78 | Testing sym_difference().
|
|---|
| 79 | ----------------------------------------------------------------------
|
|---|
| 80 | Traceback (most recent call last):
|
|---|
| 81 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 387, in test_symdifference
|
|---|
| 82 | d2 = a.sym_difference(b)
|
|---|
| 83 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 507, in sym_difference
|
|---|
| 84 | return self._geomgen(capi.geom_sym_diff, other)
|
|---|
| 85 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 471, in _geomgen
|
|---|
| 86 | return OGRGeometry(gen_func(self.ptr, other.ptr), self.srs)
|
|---|
| 87 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 84, in check_geom
|
|---|
| 88 | raise GDALException('Invalid geometry pointer returned from "%s".' % func.__name__)
|
|---|
| 89 | django.contrib.gis.gdal.error.GDALException: Invalid geometry pointer returned from "OGR_G_SymmetricDifference".
|
|---|
| 90 |
|
|---|
| 91 | ======================================================================
|
|---|
| 92 | ERROR: test_union (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 93 | Testing union().
|
|---|
| 94 | ----------------------------------------------------------------------
|
|---|
| 95 | Traceback (most recent call last):
|
|---|
| 96 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 399, in test_union
|
|---|
| 97 | u2 = a.union(b)
|
|---|
| 98 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 514, in union
|
|---|
| 99 | return self._geomgen(capi.geom_union, other)
|
|---|
| 100 | File "/media/sf_django/django/contrib/gis/gdal/geometries.py", line 471, in _geomgen
|
|---|
| 101 | return OGRGeometry(gen_func(self.ptr, other.ptr), self.srs)
|
|---|
| 102 | File "/media/sf_django/django/contrib/gis/gdal/prototypes/errcheck.py", line 84, in check_geom
|
|---|
| 103 | raise GDALException('Invalid geometry pointer returned from "%s".' % func.__name__)
|
|---|
| 104 | django.contrib.gis.gdal.error.GDALException: Invalid geometry pointer returned from "OGR_G_Union".
|
|---|
| 105 |
|
|---|
| 106 | ======================================================================
|
|---|
| 107 | FAIL: test_azimuth (gis_tests.geoapp.test_functions.GISFunctionsTests)
|
|---|
| 108 | ----------------------------------------------------------------------
|
|---|
| 109 | Traceback (most recent call last):
|
|---|
| 110 | File "/media/sf_django/django/test/testcases.py", line 1080, in skip_wrapper
|
|---|
| 111 | return test_func(*args, **kwargs)
|
|---|
| 112 | File "/media/sf_django/tests/gis_tests/geoapp/test_functions.py", line 152, in test_azimuth
|
|---|
| 113 | self.assertAlmostEqual(City.objects.annotate(azimuth=azimuth_expr).first().azimuth, math.pi / 4)
|
|---|
| 114 | AssertionError: 0.7886800845256322 != 0.7853981633974483 within 7 places
|
|---|
| 115 |
|
|---|
| 116 | ======================================================================
|
|---|
| 117 | FAIL: test_date_field (gis_tests.inspectapp.tests.OGRInspectTest)
|
|---|
| 118 | ----------------------------------------------------------------------
|
|---|
| 119 | Traceback (most recent call last):
|
|---|
| 120 | File "/media/sf_django/tests/gis_tests/inspectapp/tests.py", line 107, in test_date_field
|
|---|
| 121 | self.assertEqual(model_def, '\n'.join(expected))
|
|---|
| 122 | AssertionError: '# Th[270 chars]ed = models.DateField()\n geom = models.PointField()' != '# Th[270 chars]ed = models.DateField()\n geom = models.PointField(srid=-1)'
|
|---|
| 123 | # This is an auto-generated Django model module created by ogrinspect.
|
|---|
| 124 | from django.contrib.gis.db import models
|
|---|
| 125 |
|
|---|
| 126 | class City(models.Model):
|
|---|
| 127 | name = models.CharField(max_length=80)
|
|---|
| 128 | population = models.BigIntegerField()
|
|---|
| 129 | density = models.FloatField()
|
|---|
| 130 | created = models.DateField()
|
|---|
| 131 | - geom = models.PointField()+ geom = models.PointField(srid=-1)? +++++++
|
|---|
| 132 |
|
|---|
| 133 |
|
|---|
| 134 | ======================================================================
|
|---|
| 135 | FAIL: test_poly (gis_tests.inspectapp.tests.OGRInspectTest)
|
|---|
| 136 | ----------------------------------------------------------------------
|
|---|
| 137 | Traceback (most recent call last):
|
|---|
| 138 | File "/media/sf_django/tests/gis_tests/inspectapp/tests.py", line 80, in test_poly
|
|---|
| 139 | self.assertEqual(model_def, '\n'.join(expected))
|
|---|
| 140 | AssertionError: '# Th[231 chars]rField(max_length=80)\n geom = models.PolygonField()' != '# Th[231 chars]rField(max_length=80)\n geom = models.PolygonField(srid=-1)'
|
|---|
| 141 | # This is an auto-generated Django model module created by ogrinspect.
|
|---|
| 142 | from django.contrib.gis.db import models
|
|---|
| 143 |
|
|---|
| 144 | class MyModel(models.Model):
|
|---|
| 145 | float = models.FloatField()
|
|---|
| 146 | int = models.BigIntegerField()
|
|---|
| 147 | str = models.CharField(max_length=80)
|
|---|
| 148 | - geom = models.PolygonField()+ geom = models.PolygonField(srid=-1)? +++++++
|
|---|
| 149 |
|
|---|
| 150 |
|
|---|
| 151 | ======================================================================
|
|---|
| 152 | FAIL: test_poly_multi (gis_tests.inspectapp.tests.OGRInspectTest)
|
|---|
| 153 | ----------------------------------------------------------------------
|
|---|
| 154 | Traceback (most recent call last):
|
|---|
| 155 | File "/media/sf_django/tests/gis_tests/inspectapp/tests.py", line 85, in test_poly_multi
|
|---|
| 156 | self.assertIn('geom = models.MultiPolygonField(srid=-1)', model_def)
|
|---|
| 157 | AssertionError: 'geom = models.MultiPolygonField(srid=-1)' not found in '# This is an auto-generated Django model module created by ogrinspect.\nfrom django.contrib.gis.db import models\n\nclass MyModel(models.Model):\n float = models.FloatField()\n int = models.BigIntegerField()\n str = models.CharField(max_length=80)\n geom = models.MultiPolygonField()'
|
|---|
| 158 |
|
|---|
| 159 | ======================================================================
|
|---|
| 160 | FAIL: test_time_field (gis_tests.inspectapp.tests.OGRInspectTest)
|
|---|
| 161 | ----------------------------------------------------------------------
|
|---|
| 162 | Traceback (most recent call last):
|
|---|
| 163 | File "/media/sf_django/tests/gis_tests/inspectapp/tests.py", line 133, in test_time_field
|
|---|
| 164 | self.assertIn(' f_decimal = models.DecimalField(max_digits=0, decimal_places=0)', model_def)
|
|---|
| 165 | AssertionError: ' f_decimal = models.DecimalField(max_digits=0, decimal_places=0)' not found in '# This is an auto-generated Django model module created by ogrinspect.\nfrom django.contrib.gis.db import models\n\nclass Measurement(models.Model):\n f_decimal = models.CharField(max_length=0)\n f_float = models.CharField(max_length=0)\n f_int = models.IntegerField()\n f_char = models.CharField(max_length=0)\n f_date = models.DateField()\n f_datetime = models.DateTimeField()\n f_time = models.TimeField()\n geom = models.PolygonField()'
|
|---|
| 166 |
|
|---|
| 167 | ======================================================================
|
|---|
| 168 | FAIL: test05_geometries (gis_tests.gdal_tests.test_ds.DataSourceTest)
|
|---|
| 169 | Testing Geometries from Data Source Features.
|
|---|
| 170 | ----------------------------------------------------------------------
|
|---|
| 171 | Traceback (most recent call last):
|
|---|
| 172 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_ds.py", line 216, in test05_geometries
|
|---|
| 173 | g.srs.wkt.replace('SPHEROID["WGS_84"', 'SPHEROID["WGS_1984"')
|
|---|
| 174 | AssertionError: 'GEOG[100 chars],UNIT["Degree",0.017453292519943295]]' != 'GEOG[100 chars],UNIT["Degree",0.017453292519943295],AUTHORITY["EPSG","4326"]]'
|
|---|
| 175 | - GEOGCS["GCS_WGS_1984",DATUM["WGS_1984",SPHEROID["WGS_1984",6378137,298.257223563]],PRIMEM["Greenwich",0],UNIT["Degree",0.017453292519943295]]
|
|---|
| 176 | + GEOGCS["GCS_WGS_1984",DATUM["WGS_1984",SPHEROID["WGS_1984",6378137,298.257223563]],PRIMEM["Greenwich",0],UNIT["Degree",0.017453292519943295],AUTHORITY["EPSG","4326"]]
|
|---|
| 177 | ? +++++++++++++++++++++++++
|
|---|
| 178 |
|
|---|
| 179 |
|
|---|
| 180 | ======================================================================
|
|---|
| 181 | FAIL: test_contains (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 182 | ----------------------------------------------------------------------
|
|---|
| 183 | Traceback (most recent call last):
|
|---|
| 184 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 493, in test_contains
|
|---|
| 185 | self.assertIs(OGRGeometry('POINT(0 0)').contains(OGRGeometry('POINT(0 0)')), True)
|
|---|
| 186 | AssertionError: False is not True
|
|---|
| 187 |
|
|---|
| 188 | ======================================================================
|
|---|
| 189 | FAIL: test_crosses (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 190 | ----------------------------------------------------------------------
|
|---|
| 191 | Traceback (most recent call last):
|
|---|
| 192 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 497, in test_crosses
|
|---|
| 193 | self.assertIs(OGRGeometry('LINESTRING(0 0, 1 1)').crosses(OGRGeometry('LINESTRING(0 1, 1 0)')), True)
|
|---|
| 194 | AssertionError: False is not True
|
|---|
| 195 |
|
|---|
| 196 | ======================================================================
|
|---|
| 197 | FAIL: test_disjoint (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 198 | ----------------------------------------------------------------------
|
|---|
| 199 | Traceback (most recent call last):
|
|---|
| 200 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 502, in test_disjoint
|
|---|
| 201 | self.assertIs(OGRGeometry('LINESTRING(0 0, 0 1)').disjoint(OGRGeometry('LINESTRING(1 0, 1 1)')), True)
|
|---|
| 202 | AssertionError: False is not True
|
|---|
| 203 |
|
|---|
| 204 | ======================================================================
|
|---|
| 205 | FAIL: test_equals (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 206 | ----------------------------------------------------------------------
|
|---|
| 207 | Traceback (most recent call last):
|
|---|
| 208 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 505, in test_equals
|
|---|
| 209 | self.assertIs(OGRGeometry('POINT(0 0)').contains(OGRGeometry('POINT(0 0)')), True)
|
|---|
| 210 | AssertionError: False is not True
|
|---|
| 211 |
|
|---|
| 212 | ======================================================================
|
|---|
| 213 | FAIL: test_overlaps (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 214 | ----------------------------------------------------------------------
|
|---|
| 215 | Traceback (most recent call last):
|
|---|
| 216 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 516, in test_overlaps
|
|---|
| 217 | ), True
|
|---|
| 218 | AssertionError: False is not True
|
|---|
| 219 |
|
|---|
| 220 | ======================================================================
|
|---|
| 221 | FAIL: test_touches (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 222 | ----------------------------------------------------------------------
|
|---|
| 223 | Traceback (most recent call last):
|
|---|
| 224 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 522, in test_touches
|
|---|
| 225 | OGRGeometry('POLYGON ((0 0, 0 1, 1 1, 1 0, 0 0))').touches(OGRGeometry('LINESTRING(0 2, 2 0)')), True
|
|---|
| 226 | AssertionError: False is not True
|
|---|
| 227 |
|
|---|
| 228 | ======================================================================
|
|---|
| 229 | FAIL: test_within (gis_tests.gdal_tests.test_geom.OGRGeomTest)
|
|---|
| 230 | ----------------------------------------------------------------------
|
|---|
| 231 | Traceback (most recent call last):
|
|---|
| 232 | File "/media/sf_django/tests/gis_tests/gdal_tests/test_geom.py", line 528, in test_within
|
|---|
| 233 | OGRGeometry('POINT(0.5 0.5)').within(OGRGeometry('POLYGON ((0 0, 0 1, 1 1, 1 0, 0 0))')), True
|
|---|
| 234 | AssertionError: False is not True
|
|---|