In fact I thought it was illegal for employers to ask.
Religious institutions have the right to discriminate in hiring.
Title VII of the Civil Rights Act of 1964 acknowledges the appropriateness of allowing employers (including educational institutions) controlled by religious organizations to hire only members of that religion 42 USC 2000e-2(e). Similarly, Title IX of the Education Amendments of 1972 provides an exemption to educational institutions controlled by a religious organization whose tenets conflict with the requirements of Title IX, and the Americans with Disabilities Act permits religious entities to give preference in employment to individuals of a particular religion and permits such entities to require applicants and employees to conform to the religious tenets of the organization. 20 USC 1681(a)(3); 42 USC 12113(c).
That doesn't necessarily make it right. Do you have to be a christian to wash floors in a baptist church?
I do think it is valid and reasonable for a business\operation\organization\etc to say "These are the principles that you agree to in joining us: (list), and if there are any that you feel you cannot do then we expect you to willingly withdraw, and failure to do so is taken as willingness to abide by the principles."
For Woods Hole that would mean saying we are a biological lab, and we do biology, including evolution.
If something comes up that is off the list then that is a matter for discussion or negotiation regarding termination etc if it is not reconcilable. The employer learns to add something to their list and the employee should be compensated.