[
https://issues.apache.org/jira/browse/THRIFT-109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12638076#action_12638076
]
David Reiss commented on THRIFT-109:
------------------------------------
bq. Anyway, I concur that assertAlmostEqual might not be the most appropiate
method here, what about self.assert_(time.time() - starttime < 5.0) ?
Sounds good. Do you want to post an updated patch?
bq. self.assert* should receive the expected value as the first argument and
the resulting one as the second.
I personally like it the other way, but personal preferences aside, it look
like the few examples here:
http://www.python.org/doc/2.5.2/lib/module-unittest.html have the actual value
first and the expected value second. Obviously, this is not a critically
important issue.
> Python unit tests should use self.assert*
> -----------------------------------------
>
> Key: THRIFT-109
> URL: https://issues.apache.org/jira/browse/THRIFT-109
> Project: Thrift
> Issue Type: Improvement
> Components: Test Suite
> Reporter: Esteve Fernandez
> Priority: Minor
> Attachments: py_unittests.patch
>
>
> In some of tests in the current testsuite for Python use, "assert EXPR"
> instead of the standard self.assert* methods. It's recommended using these
> methods as they give more information in case an assertion fails.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.