Add compare and tests