The ability of the developing lung to oxygenate and ventilate effectively outside the womb. The readiness of the fetal lung can be assessed with several invasive (e.g., amniocentesis) and noninvasive (e.g., ultrasound) tests, all of which have some shortcomings. Some tests on amniotic fluid include: measurements of surfactant; phosphatidylglycerol; the lecithin/sphingomyelin ratio; and the number of lamellar bodies.