The question you raised about the 10 year old is fast becoming moot because fetal genetic testing has become a routine part of prenatal care in the USA - and it’s fast on its way to becoming more the norm than not. Already, the majority of pregnant women in the US get the NIPT fairly early on in pregnancy.
The NIPT, which stands for non-invasisive prenatal testing, analyzes fragments of fetal DNA in a sample of a pregnant woman’s blood drawn from one of her veins in the standard way used for most blood tests.
The NIPT determines the sex chromosomes and SRY gene status of a fetus with close to 100% accuracy. It can be done as early as 8-9 weeks, and is most accurate through week 17. Most pregnant women get the NIPT around week 11-14.
Since 2020, US health authorities have recommended the NIPT for all pregnant women except in the cases of pregnancies with three or more fetuses. Virtually all private and public health insurance in the US now covers the NIPT; and in some states, there isn’t even a copay.
Since 2020, between 2 and 3 million women in the USA have gotten the NIPT each year - accounting for about 65% of all babies born in the USA during that time. My impression is that by the end of the decade, the chromosomal and genetic sex of upwards of 90% of babies born in the USA will have have been ascertained through the NIPT many months before they were born.
Before the NIPT came into clinical use and started to become commercially available in 2011, many prengnant women in the USA had fetal DNA screening which could tell the chromosomal and genetic sex of developing offsping using genetic material obtained through more invasive methods.
Amniocentesis first became possible in the late 1950s, and it started to be done safely using sonogram technology to guide the needle in the early 1970s. Chorionic villi sampling first became available in the USA in the mid-late 1980s.
I had CVS when I was 8-9 weeks pregnant with each of my children in the early 1990s. Although my partner and I chose not to be informed of our offspring's sex before they were born, my children's chromosomal and genetic sex was nevertheless scientifcally ascertained and recorded in their and my medical records nearly 7 months before each of them was born.
Also, from week 14 on, the sex of a human fetus can be determined with near 100% accuracy through another widely-used non-invasive method that's been around a long time time - scans that give detailed images of fetal anatomy including the genitals that are obtained by using a sonogram probe on the outside of the pregnant women’s abdomen.
Since the 1980s, a prenatal sonogram in the second trimester has been a standard part of basic prenatal care in the USA and many other countries.
Nowadays many women get an additional scan in the third trimester too - which is why it’s now known that one out of every 2,500 female fetuses has an ovarian cyst requiring monitoring and often medical intervention before or soon after birth.
In addition, for many decades now, every US state, territory and the District of Columbia has made it mandatory for all babies born in their jurisdiction to be screened for many dozens of inborn genetic health conditions using a sample of blood obtained from pricking one of their heels with a needle soon after birth. The blood is preserved on blotter paper and sent to state health department labs for analysis.
States in the USA vary when it comes to exactly what conditions they screen newborns for, and in the overall number of conditions checked. Most states use the dried blood samples to check newborns for about 40-50 different conditions, but a few check for more than 80.
You can’t get a birth certificate for a baby born in the USA without the child going through the newborn screening required by the jurisdiction where they were born. Even if you give birth at home, the baby has to have NBS to get a BC.
Whilst none of the NBS programs in the USA currently use the blood samples of babies to do DNA sex testing, they very easily could - and discussions are ongoing in quite a few states about whether they should.
China - which in recent years has joined the USA in being a world leader in NBS - has started using DNA analysis of newborns’ bloodspots as the first line of screening rather than the longstanding methods of biochemical analysis still customarily used in the USA. In the USA, DNA testing is usually the second-line form of testing used only after biochemical bloodspot analysis that's intitally done yields a result indicating that more testing for a particular condition or set of conditions is called for.