removed unused equals() and add some unit tests