summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorKevan Swanberg <kevswanberg@gmail.com>2016-07-21 16:54:07 -0400
committerTim Graham <timograham@gmail.com>2016-08-30 20:45:47 -0400
commit35504f74a8c3b45d308969a77488d11443ce4348 (patch)
tree5aeccff79a3bb4f27c943b003cf0af4900d76abe /tests
parent0d7929266ec9d8f6bcf9e41a40b281259cba6a79 (diff)
Fixed #26685 -- Added dwithin lookup support on SpatiaLite.
Diffstat (limited to 'tests')
-rw-r--r--tests/gis_tests/distapp/tests.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/gis_tests/distapp/tests.py b/tests/gis_tests/distapp/tests.py
index fd4e6dfaca..cb0c422a54 100644
--- a/tests/gis_tests/distapp/tests.py
+++ b/tests/gis_tests/distapp/tests.py
@@ -10,7 +10,7 @@ from django.db.models import F, Q
from django.test import TestCase, ignore_warnings, skipUnlessDBFeature
from django.utils.deprecation import RemovedInDjango20Warning
-from ..utils import no_oracle, oracle, postgis
+from ..utils import no_oracle, oracle, postgis, spatialite
from .models import (
AustraliaCity, CensusZipcode, Interstate, SouthTexasCity, SouthTexasCityFt,
SouthTexasInterstate, SouthTexasZipcode,
@@ -82,9 +82,11 @@ class DistanceTest(TestCase):
type_error = False
if isinstance(dist, tuple):
- if oracle:
+ if oracle or spatialite:
+ # Result in meters
dist = dist[1]
else:
+ # Result in units of the field
dist = dist[0]
# Creating the query set.