Written and passes methods to refactor the expectEquals method