They say that color blindness can be predicted in some cases, but it cannot be detected before birth, because there are many causes for color blindness. When the fetus is in utero, it cannot be determined yet. I also know that color blindness can be a recessive trait. It is carried on the X chromosome. Maybe your baby will have this kind of vision problem too. But I think you should consult your doctor.
I know that achromatopsia is an inherited condition. It only affects approximately 1 in every 33,000 Americans. But I also know that the earliest test for color blindness is from three to five years old. It is the time when your child can help identify what colors they can see. So I think color blindness cannot be detected before the birth of your baby.