[Python-modules-commits] r34074 - in packages/djangorestframework-gis/trunk/debian/patches (1 file)

fladi at users.alioth.debian.org fladi at users.alioth.debian.org
Tue Sep 1 05:38:05 UTC 2015


    Date: Tuesday, September 1, 2015 @ 05:38:04
  Author: fladi
Revision: 34074

Update debian/patches/spatialite.patch to work with libsqlite3-mod-spatialite (Closes: #793526).

Modified:
  packages/djangorestframework-gis/trunk/debian/patches/spatialite.patch

Modified: packages/djangorestframework-gis/trunk/debian/patches/spatialite.patch
===================================================================
--- packages/djangorestframework-gis/trunk/debian/patches/spatialite.patch	2015-08-31 21:35:36 UTC (rev 34073)
+++ packages/djangorestframework-gis/trunk/debian/patches/spatialite.patch	2015-09-01 05:38:04 UTC (rev 34074)
@@ -5,13 +5,15 @@
  the PostGIS driver.
  See the following URL for a compatibility matrix:
  https://docs.djangoproject.com/en/1.7/ref/contrib/gis/db-api/#compatibility-tables
-Author: Michael Fladischer <FladischerMichael at fladi.at>
+Author: Michael Fladischer <fladi at debian.org>
 Last-Update: 2014-10-12
 Forwarded: not-needed
 
---- a/tests/settings.py
-+++ b/tests/settings.py
-@@ -5,12 +5,8 @@
+Index: djangorestframework-gis/tests/settings.py
+===================================================================
+--- djangorestframework-gis.orig/tests/settings.py	2015-08-31 19:50:59.446139272 +0200
++++ djangorestframework-gis/tests/settings.py	2015-08-31 21:13:33.447199982 +0200
+@@ -5,15 +5,15 @@
  
  DATABASES = {
      'default': {
@@ -26,21 +28,14 @@
      },
  }
  
-@@ -18,11 +14,11 @@
++# Support mod_spatialite:
++# https://code.djangoproject.com/ticket/23901
++SPATIALITE_LIBRARY_PATH = 'mod_spatialite'
++
+ SECRET_KEY = 'fn)t*+$)ugeyip6-#txyy$5wf2ervc0d2n#h)qb)y5 at ly$t*@w'
  
  INSTALLED_APPS = (
-     'django.contrib.staticfiles',
--    
-+
-     # rest framework
-     'rest_framework',
-     'rest_framework_gis',
--    
-+
-     # test app
-     'django_restframework_gis_tests'
- )
-@@ -40,6 +36,8 @@
+@@ -45,6 +45,8 @@
  STATIC_ROOT = '%s/static/' % SITE_ROOT
  STATIC_URL = '/static/'
  
@@ -49,39 +44,3 @@
  TEMPLATE_STRING_IF_INVALID = 'INVALID_TEMPLATE: %s END_INVALID_TEMPLATE'
  
  # local settings must be imported before test runner otherwise they'll be ignored
---- a/tests/django_restframework_gis_tests/tests.py
-+++ b/tests/django_restframework_gis_tests/tests.py
-@@ -9,7 +9,9 @@
- 
- 
- import urllib
-+from django.conf import settings
- from django.test import TestCase
-+from django.test.testcases import skipIf
- from django.contrib.gis.geos import GEOSGeometry, Polygon
- from django.core.urlresolvers import reverse
- 
-@@ -471,6 +473,7 @@
-         for result in response.data['features']:
-             self.assertEqual(result['properties']['name'] in ('isContained', 'isEqualToBounds', 'overlaps'), True)
- 
-+    @skipIf(settings.DATABASES['default']["ENGINE"] != "django.contrib.gis.db.backends.postgis", "PostGIS not installed")
-     def test_TileFilter_filtering(self):
-         """
-         Checks that the TMSTileFilter returns only objects strictly contained
-@@ -520,6 +523,7 @@
-         for result in response.data['features']:
-             self.assertEqual(result['properties']['name'] in ('isContained', 'isEqualToBounds', 'overlaps'), True)
- 
-+    @skipIf(settings.DATABASES['default']["ENGINE"] != "django.contrib.gis.db.backends.postgis", "PostGIS not installed")
-     def test_DistanceToPointFilter_filtering(self):
-         """
-         Checks that the DistancFilter returns only objects within the given distance of the
-@@ -655,6 +659,7 @@
-         for result in response.data['features']:
-             self.assertEqual(result['properties']['name'] in (treasure_island.name), True)
- 
-+    @skipIf(settings.DATABASES['default']["ENGINE"] != "django.contrib.gis.db.backends.postgis", "PostGIS not installed")
-     def test_GeometryField_filtering(self):
-         """ Checks that the GeometryField allows sane filtering. """
-         self.assertEqual(Location.objects.count(), 0)




More information about the Python-modules-commits mailing list