title: Why would mock be adding __nonzero__ method calls?
body: <p>I've got a bit of code that makes a call to a series of methods on each item in a collection, and each method returns a boolean value indicating success = True/failure = False.</p>
  
  <pre><code>def monkey(some_collection, arg1, arg2):
      for item in some_collection:
          if not item.foo(arg1, arg2):
              continue
          if not item.bar(arg1, arg2):
              continue
          if not item.baz(arg1, arg2):
              continue
  </code></pre>
  
  <p>And, here's my unit test example: </p>
  
  <pre><code>import mock
  def TestFoo(unittest.TestCase):
      def test_monkey(self):
          item = MagicMock()
          some_collection = [item]
          collection_calls = []
          foo_call = mock.call().foo(some_collection, 1, 2)
          bar_call = mock.call().bar(some_collection, 1, 2)
          baz_call = mock.call().baz(some_collection, 1, 2)
          collection_calls = [foo_call, bar_call, baz_call]                   
          my_module.monkey(some_collection, 1, 2)
          item.assert_has_calls(collection_calls) # requires the correct call order/sequence
  </code></pre>
  
  <p><strong>Actual Calls</strong></p>
  
  <ol>
  <li><code>call().foo(&lt;MagicMock id='12345'&gt;, 1, 2)</code></li>
  <li><code>call().foo.__nonzero__()</code></li>
  </ol>
  
  <p>...</p>
  
  <p><em>NOTE:  This unit test fails because its seeing the <code>__nonzero__()</code> method calls.</em></p>
  
  <p><strong>Question</strong></p>
  
  <p>Why is it adding the nonzero method calls?</p>
  
  <p><strong>Clarification</strong></p>
  
  <p>I'm using <a href="http://pypi.python.org/pypi/mock">mock</a>, which is included in stdlib as of python 3.3.  </p>