Contains test for python objects
<p>How does Python <code>__contains__</code> work for lists if I use arbitrary objects for elements?
Will it revert to the <code>is</code> operator? Or does it use <code>__eq__</code> if provided?</p>

<p>A simple test gave</p>

<pre><code>class Test: pass

print(Test() in [Test()]) # -&gt; no
a=Test() 
print(a in [a])   # -&gt; yes
print(a in [Test()])  # -&gt; no
</code></pre>

<p>So can I assume it uses the comparison by references <code>is</code>?</p>
