Added test case for Eq type class.

Actually, the bug is still present if one uses the Eq type class. I used the type class explicitly in the test because === seems to be overridden.