Equality per entity type

Noticed that my tests are not comparing all entities, because IDs were the only criteria for comparison. I believe it is intended to include the entity's type as well.