Closed ZhongweiL closed 2 years ago
I want a full report on how this change was tested and what the results were. Last time we merged such a change, we didn't find a problem with it until we used the web app. Thus, as part of this PR, I should see test code that exercises the changed code. Since the problem has time was with categorization viewing, I would expect to see test code that covers that case.
I want a full report on how this change was tested and what the results were. Last time we merged such a change, we didn't find a problem with it until we used the web app. Thus, as part of this PR, I should see test code that exercises the changed code. Since the problem has time was with categorization viewing, I would expect to see test code that covers that case.
It was tested by accessing the Categorizations page, since that was the bug.
Intends to resolve #147 and #158 . As described in issue #158 an exception with the value
__str__ returned non-string (type User)
was thrown when the Categorizations page was accessed. The problem is with the string representation of Categorizer defined in__str__
function. It returnsself.user
, which originally refers to a string type. However, after the user field was converted to a foreign key,self.user
would be referring to a User object, which gave us the error. To resolve that, I converted the User to its string representation before returning.