CNN  — 

South African runner Caster Semenya on Friday won what’s expected to be her last 800-meter race before new testosterone-limiting rules go into effect for women’s middle-distance track events.

Semenya, a double Olympic champion over 800 meters, ran a meet-record time of 1:54.98 on Friday at the IAAF Diamond League event in Doha, Qatar, beating her nearest competitor by nearly 3 seconds.

The race comes two days after she lost an appeal against new rules regulating the testosterone levels for athletes with a difference in sex development (DSD).

Semenya, a 28-year-old who has been the dominant force in women’s middle-distance running, is hyperandrogenous, meaning she has elevated levels of testosterone.

Under an International Association of Athletics Federations policy scheduled to go into effect Wednesday, she would need to take medication to reduce her testosterone if she wants to compete internationally in women’s events between 400 meters and one mile.

Caster Semenya of South Africa races to the line to win the women's 800 meters at the IAAF Diamond League event Friday in Doha, Qatar.

Though the Court of Arbitration for Sport rejected Semenya’s challenge against the policy, she still could appeal the decision to the Swiss Federal Tribunal.

Semenya’s next step in the sport isn’t clear. Thursday, she cryptically posted an image with the following words: “Knowing when to walk away is wisdom. Being able to is courage. Walking away with your head held high is dignity.”

CNN’s Aimee Lewis, Eoghan Macguire and Chris Eldergill contributed to this report.