make is_masquerading_as_student work with Mock for tests

This commit is contained in:
ichuang
2013-04-13 21:38:12 -04:00
parent 857a6e0bd0
commit 1c2452e401

View File

@@ -58,4 +58,4 @@ def is_masquerading_as_student(user):
Return True if user is masquerading as a student, False otherwise
'''
masq = getattr(user, 'masquerade_as_student', False)
return masq
return masq==True