World Athletics will introduce mandatory testing for anyone entering female competitions to verify their biological sex, insisting they are necessary to protect women's sport.