From b88aea76e97f43eb2c31e25c05d8cc20dc51a194 Mon Sep 17 00:00:00 2001 From: Craig Blaszczyk Date: Thu, 8 Jan 2015 17:51:03 +0000 Subject: [PATCH] update expected error messages --- tests/test_settings.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/test_settings.py b/tests/test_settings.py index cabc9a056..bbf62b667 100644 --- a/tests/test_settings.py +++ b/tests/test_settings.py @@ -1,7 +1,6 @@ from __future__ import unicode_literals from django.core.exceptions import ImproperlyConfigured import pytest -import warnings from django.test import TestCase from rest_framework.settings import APISettings @@ -32,7 +31,9 @@ class TestSettings(TestCase): with pytest.raises(ImproperlyConfigured) as exc_info: settings.DEFAULT_RENDERER_CLASSES expected_error = ( - u'The "DEFAULT_RENDERER_CLASSES" setting must be a list or a tuple' + u'The "DEFAULT_RENDERER_CLASSES" setting must be a list or ' + u'tuple, but got type "unicode" with value ' + u'"rest_framework.renderers.JSONRenderer".' ) assert exc_info.value[0] == expected_error @@ -50,6 +51,7 @@ class TestSettings(TestCase): settings.DEFAULT_METADATA_CLASS expected_error = ( - u'The "DEFAULT_METADATA_CLASS" setting must be a string' + u'The "DEFAULT_METADATA_CLASS" setting must be a string, but got ' + u'type "list" with value "[]".' ) assert exc_info.value[0] == expected_error