Extract RestfulModel tests into shared examples