Add spec for errors