Commit 8e08ff52 by Daniel Friedman Committed by Andy Armstrong

Rebase cleanup

parent 6f6fdbfb
......@@ -178,6 +178,11 @@ class TestAccountApi(TestCase):
self.assertEqual(0, len(pending_change))
@patch('openedx.core.djangoapps.user_api.accounts.helpers._PROFILE_IMAGE_SIZES', [50, 10])
@patch.dict(
'openedx.core.djangoapps.user_api.accounts.helpers.PROFILE_IMAGE_SIZES_MAP', {'full': 50, 'small': 10}, clear=True
)
@unittest.skipUnless(settings.ROOT_URLCONF == 'lms.urls', 'Account APIs are only supported in LMS')
class AccountSettingsOnCreationTest(TestCase):
USERNAME = u'frank-underwood'
......@@ -209,6 +214,12 @@ class AccountSettingsOnCreationTest(TestCase):
'mailing_address': None,
'year_of_birth': None,
'country': None,
'bio': None,
'profile_image': {
'has_image': False,
'image_url_full': 'http://example-storage.com/profile_images/default_50.jpg',
'image_url_small': 'http://example-storage.com/profile_images/default_10.jpg',
},
})
......
......@@ -153,7 +153,7 @@ class TestAccountAPI(UserAPITestCase):
Verify that all account fields are returned (even those that are not shareable).
"""
data = response.data
self.assertEqual(13, len(data))
self.assertEqual(14, len(data))
self.assertEqual(self.user.username, data["username"])
self.assertEqual(self.user.first_name + " " + self.user.last_name, data["name"])
self.assertEqual("US", data["country"])
......@@ -269,7 +269,7 @@ class TestAccountAPI(UserAPITestCase):
def verify_get_own_information():
response = self.send_get(self.client)
data = response.data
self.assertEqual(13, len(data))
self.assertEqual(14, len(data))
self.assertEqual(self.user.username, data["username"])
self.assertEqual(self.user.first_name + " " + self.user.last_name, data["name"])
for empty_field in ("year_of_birth", "level_of_education", "mailing_address", "bio"):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment