summaryrefslogtreecommitdiff
path: root/tests/modeltests/raw_query
diff options
context:
space:
mode:
authorJacob Kaplan-Moss <jacob@jacobian.org>2011-03-14 19:49:53 +0000
committerJacob Kaplan-Moss <jacob@jacobian.org>2011-03-14 19:49:53 +0000
commitfd2f18008caeca28c60c43cce7b43fb87c6fee78 (patch)
tree0b8379fa6a746954811b76e022c182fc6cb62354 /tests/modeltests/raw_query
parentf1f10a9ce2d8cd8df0dbd4b922fd2dba335a3770 (diff)
Fixed #14733: no longer "validate" .raw() queries.
Turns out that a lot more than just SELECT can return data, and this list is very hard to define up front in a cross-database manner. So let's just assume that anyone using raw() is at least halfway competant and can deal with the error messages if they don't use a data-returning query. Thanks to Christophe Pettus for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15803 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests/modeltests/raw_query')
-rw-r--r--tests/modeltests/raw_query/tests.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/tests/modeltests/raw_query/tests.py b/tests/modeltests/raw_query/tests.py
index 5334412680..aa6aec10b1 100644
--- a/tests/modeltests/raw_query/tests.py
+++ b/tests/modeltests/raw_query/tests.py
@@ -169,10 +169,6 @@ class RawQueryTests(TestCase):
authors = Author.objects.all()
self.assertSuccessfulRawQuery(Author, query, authors, expected_annotations)
- def testInvalidQuery(self):
- query = "UPDATE raw_query_author SET first_name='thing' WHERE first_name='Joe'"
- self.assertRaises(InvalidQuery, Author.objects.raw, query)
-
def testWhiteSpaceQuery(self):
query = " SELECT * FROM raw_query_author"
authors = Author.objects.all()