MPs will vote on whether the government broke Parliament’s rules by not publishing Brexit legal advice.