It stinks. In a way, they're going backwards. Check out this excerpt talking about the highly sexist Ancient games - at least their barbaric sex test meant something (I'm not advocating the sex testing and especially not the way it was applied to Semenya, but just saying, at least the Greeks abided by it and would've ruled Semenya is in fact, a woman, something the IAAF is not saying):
"Adult women (those who were married) were prohibited from attending the Olympics by the laws of Ellis (the city that hosted the games). If a female participant was caught in the Olympic stadium, the city of Ellis stated that they were to be thrown into the river from Mount Typaion. (1) This law while harsh and possibly lethal was never recorded as being enforced, and in fact, there is a story of a women who had violated the Olympic game’s law and social norm.
Kallipateira, from a noble family, disguised herself as a trainer to watch her son fight and win the Olympic prize for Boxing. During the award ceremony, Kallipateria rushed out to greet her son and congratulate him. Due to her status, she went unpunished but because of her actions at every Olympics after, trainers had to enter naked (to prove their gender)."