Issue 34 in pymox: Mox ExpectedMethodCallsError's _str__ method prints out one character per line

瀏覽次數:19 次
跳到第一則未讀訊息

codesite...@google.com

未讀,
2011年5月26日 清晨5:02:262011/5/26
收件者:mox-d...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 34 by almostob...@gmail.com: Mox ExpectedMethodCallsError's
_str__ method prints out one character per line
http://code.google.com/p/pymox/issues/detail?id=34

See:
http://stackoverflow.com/questions/6124180/python-nose-tests-actually-the-error-is-from-mox-print-out-errors-one-character

My Fix:

Adding this line to the top of str method of ExpectedMethodCallsError in
mox.py fixes the problem (or this symptom anyway):

if isinstance(self._expected_methods, str):
self._expected_methods = self._expected_methods.split("\n")

codesite...@google.com

未讀,
2011年6月6日 下午2:56:362011/6/6
收件者:mox-d...@googlegroups.com

Comment #1 on issue 34 by stev...@google.com: Mox
ExpectedMethodCallsError's _str__ method prints out one character per line
http://code.google.com/p/pymox/issues/detail?id=34

Hm, this is a strange one, and it seems more like a bandaid than a proper
fix. The real problem seems to be that the self._expected_calls_queue is
being populated with a string somehow, instead of being used as a deque().

codesite...@google.com

未讀,
2012年7月17日 晚上7:50:112012/7/17
收件者:mox-d...@googlegroups.com

Comment #2 on issue 34 by jeblai...@gmail.com: Mox
ExpectedMethodCallsError's _str__ method prints out one character per line
http://code.google.com/p/pymox/issues/detail?id=34

I believe this is actually a problem in Nose, see:
https://github.com/nose-devs/nose/issues/529


回覆所有人
回覆作者
轉寄
0 則新訊息