Using method is_equal_to instead of comparing properties