Texas judge rules that women with pregnancy complications are exempt from state