aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorTom Christie2014-11-28 15:36:04 +0000
committerTom Christie2014-11-28 15:36:04 +0000
commit3a5b3772fefc3c2f2c0899947cbc07bfe6e6b5d2 (patch)
tree62da2ff99cee21b83c3dd735b2d75fe08a4ef5e0 /tests
parent6fbd23ab346e1a5b5401ba83e2ad2cd3474d2410 (diff)
downloaddjango-rest-framework-3a5b3772fefc3c2f2c0899947cbc07bfe6e6b5d2.tar.bz2
Use ImproperlyConfigured when model meta lookup fails
Diffstat (limited to 'tests')
-rw-r--r--tests/test_utils.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/test_utils.py b/tests/test_utils.py
index 0bdb36bb..8c286ea4 100644
--- a/tests/test_utils.py
+++ b/tests/test_utils.py
@@ -1,4 +1,5 @@
from __future__ import unicode_literals
+from django.core.exceptions import ImproperlyConfigured
from django.conf.urls import patterns, url
from django.test import TestCase
from django.utils import six
@@ -161,5 +162,5 @@ class ResolveModelWithPatchedDjangoTests(TestCase):
rest_framework.utils.model_meta.models.get_model = self.get_model
def test_blows_up_if_model_does_not_resolve(self):
- with self.assertRaises(ValueError):
+ with self.assertRaises(ImproperlyConfigured):
_resolve_model('tests.BasicModel')