From d4ce82a4f9390d6c5af1817cece345897234a2e9 Mon Sep 17 00:00:00 2001 From: Jeremy Bowman Date: Thu, 19 Oct 2017 18:06:26 -0400 Subject: [PATCH] PLAT-1542 No callable queryset method arguments --- lms/djangoapps/instructor/tests/test_api.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lms/djangoapps/instructor/tests/test_api.py b/lms/djangoapps/instructor/tests/test_api.py index dc0cd0e922..490df84237 100644 --- a/lms/djangoapps/instructor/tests/test_api.py +++ b/lms/djangoapps/instructor/tests/test_api.py @@ -22,7 +22,7 @@ from django.test import RequestFactory, TestCase from django.test.utils import override_settings from pytz import UTC from django.utils.translation import ugettext as _ -from mock import Mock, patch +from mock import Mock, NonCallableMock, patch from nose.plugins.attrib import attr from nose.tools import raises from opaque_keys.edx.keys import CourseKey @@ -485,7 +485,7 @@ class TestInstructorAPIDenyLevels(SharedModuleStoreTestCase, LoginEnrollmentTest msg: message to display if assertion fails. """ - mock_problem_key = Mock(return_value=u'') + mock_problem_key = NonCallableMock(return_value=u'') mock_problem_key.course_key = self.course.id with patch.object(UsageKey, 'from_string') as patched_method: patched_method.return_value = mock_problem_key